TiDB5.4集群配置


编辑 topology.yaml

 1 [tidb@test11 ~]$ cat topology.yaml
 2 global:
 3   user: "tidb"
 4   ssh_port: 22
 5   deploy_dir: "/data/tidb-deploy"
 6   data_dir: "/data/tidb-data"
 7 #  arch: "amd64"
 8 monitored:
 9   node_exporter_port: 9100
10   blackbox_exporter_port: 9115
11 pd_servers:
12   - host: 10.172.32.101
13   - host: 10.172.32.102
14   - host: 10.172.32.103
15 tidb_servers:
16   - host: 10.172.32.101
17   - host: 10.172.32.102
18   - host: 10.172.32.103
19 tikv_servers:
20   - host: 10.172.32.104
21   - host: 10.172.32.105
22   - host: 10.172.32.106
23 tiflash_servers:
24   - host: 10.172.32.107
25   - host: 10.172.32.108
26 monitoring_servers:
27   - host: 10.172.32.109
28 grafana_servers:
29   - host: 10.172.32.110
30 alertmanager_servers:
31   - host: 10.172.32.111
32 [tidb@test11 ~]$ 
topology.yaml

[tidb@test11 ~]$ mysql -uroot -h10.172.32.101 -P4000 -p
Enter password:
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MySQL connection id is 135
Server version: 5.7.25-TiDB-v5.4.0 TiDB Server (Apache License 2.0) Community Edition, MySQL 5.7 compatible

Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MySQL [(none)]> show databases;
+--------------------+
| Database |
+--------------------+
| INFORMATION_SCHEMA |
| METRICS_SCHEMA |
| PERFORMANCE_SCHEMA |
| mysql |
| test |
+--------------------+
5 rows in set (0.00 sec)

MySQL [(none)]>