执行:tiup cluster deploy mytidb 5.4.1 ./topo.yaml --user root -p
报错:
Error: Failed to parse topology file ./topo.yaml (topology.parse_failed)
caused by: yaml: unmarshal errors:
line 4: field user not found in type spec.topology
line 5: field ssh_port not found in type spec.topology
line 6: field deploy_dir not found in type spec.topology
line 7: field data_dir not found in type spec.topology
line 10: field node_exporter_port not found in type spec.topology
line 11: field blackbox_exporter_port not found in type spec.topology
line 13: field tidb not found in type spec.topology
line 14: field log.slow-threshold not found in type spec.topology
line 15: field tikv not found in type spec.topology
line 16: field readpool.storage.use-unified-pool not found in type spec.topology
line 17: field readpool.coprocessor.use-unified-pool not found in type spec.topology
line 18: field pd not found in type spec.topology
line 19: field replication.enable-placement-rules not found in type spec.topology
line 20: field replication.location-labels not found in type spec.topology
line 21: field tiflash not found in type spec.topology
line 22: field logger.level not found in type spec.topology
line 32: field port not found in type spec.topology
line 33: field status_port not found in type spec.topology
line 34: field config not found in type spec.topology
line 35: field server.labels not found in type spec.topology
line 37: field -host not found in type spec.topology
line 48: cannot unmarshal !!map into []*spec.TiFlashSpec
line 51: cannot unmarshal !!map into []*spec.PrometheusSpec
line 54: cannot unmarshal !!map into []*spec.GrafanaSpec
Please check the syntax of your topology file ./topo.yaml and try again.
topo.yaml(语法检验通过):
# Global variables are applied to all deployments and used as the default value of
# the deployments if a specific deployment value is missing.
global:
user: “tidb”
ssh_port: 22
deploy_dir: “/root/tidb-deploy”
data_dir: “/root/tidb-data”
# Monitored variables are applied to all the machines.
monitored:
node_exporter_port: 9100
blackbox_exporter_port: 9115
server_configs:
tidb:
log.slow-threshold: 300
tikv:
readpool.storage.use-unified-pool: false
readpool.coprocessor.use-unified-pool: true
pd:
replication.enable-placement-rules: true
replication.location-labels: [“host”]
tiflash:
logger.level: “info”
pd_servers:
- host: 192.168.0.102
tidb_servers:
- host: 192.168.0.102
tikv_servers:
- host: 192.168.0.102
port: 20160
status_port: 20180
config:
server.labels: { host: “logic-host-1” }
-host: 192.168.0.102
port:20161
status_port:20181
config:server.labels:{host:“logic-host-2” }
-host:192.168.0.102
port:20162
status_port:20182
config:server.labels:{ host:“logic-host-3” }
tiflash_servers:
-host: 192.168.0.102
monitoring_servers:
-host: 192.168.0.102
grafana_servers:
-host: 192.168.0.102