## 模块 4: 连接到 TiDB Server

### 步骤 1. 连接到 TiDB

  ```bash
  mysql -h ${HOST_DB1_PRIVATE_IP} --port 4000 -u root
  ```

### 步骤 2. 查看 TiDB 集群的版本

  ```sql
  SELECT TIDB_VERSION()\G
  ```

  ```output
  *************************** 1. row ***************************
  TIDB_VERSION(): Release Version: v7.5.0
  Edition: Community
  Git Commit Hash: 069631e2ecfedc000ffb92c67207bea81380f020
  Git Branch: heads/refs/tags/v7.5.0
  UTC Build Time: 2023-11-24 08:50:14
  GoVersion: go1.21.3
  Race Enabled: false
  TiKV Min Version: 7.2.0-alpha
  Check Table Before Drop: false
  Store: tikv
  1 row in set (0.00 sec)
  ```

### 步骤 3. 退出到控制机终端

  ```sql
  EXIT;
  ```

  ```output
  Bye
  ```
