Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: line 58: field pd not found in type spec.topology
【TiDB Usage Environment】Production\Test Environment\POC
【TiDB Version】6.1
【Encountered Problem】
Error: Failed to parse topology file ./topology.yaml (topology.parse_failed)
caused by: yaml: unmarshal errors:
line 58: field pd not found in type spec.topology
【Reproduction Path】What operations were performed to encounter the problem
【Problem Phenomenon and Impact】
The configuration file is as follows
pd:
replication.enable-placement-rules: true
replication.location-labels: ["host"]
# tiflash:
# tiflash-learner:
# # Server configs are used to specify the configuration of PD Servers.
pd_servers:
# # The ip address of the PD Server.
- host: 192.168.56.3
# # SSH port of the server.
# ssh_port: 22
# # PD Server name
# name: "pd-1"
# # communication port for TiDB Servers to connect.
# client_port: 2379
# # Communication port among PD Server nodes.
peer_port: 2380
# # PD Server deployment file, startup script, configuration file storage directory.
# deploy_dir: "/tidb-deploy/pd-2379"
# # PD Server data storage directory.
# data_dir: "/tidb-data/pd-2379"
# # PD Server log file storage directory.
# log_dir: "/tidb-deploy/pd-2379/log"
# # numa node bindings.
# numa_node: "0,1"
# # The following configs are used to overwrite the `server_configs.pd` values.
# config:
# schedule.max-merge-region-size: 20
# schedule.max-merge-region-keys: 200000
# # Server configs are used to specify the configuration of TiDB Servers.
tidb_servers:
# # The ip address of the TiDB Server.
- host: 192.168.56.3
# # SSH port of the server.
# ssh_port: 22
# # The port for clients to access the TiDB cluster.
port: 4000
# # TiDB Server status API port.
status_port: 10080
# # TiDB Server deployment file, startup script, configuration file storage directory.
# deploy_dir: "/tidb-deploy/tidb-4000"
# # TiDB Server log file storage directory.
# log_dir: "/tidb-deploy/tidb-4000/log"
# # The ip address of the TiDB Server.
- host: 192.168.56.3
# ssh_port: 22
port: 4001
status_port: 10081
# deploy_dir: "/tidb-deploy/tidb-4000"
# log_dir: "/tidb-deploy/tidb-4000/log"
- host: 192.168.56.3
# ssh_port: 22
port: 4002
status_port: 10082
# deploy_dir: "/tidb-deploy/tidb-4000"
# log_dir: "/tidb-deploy/tidb-4000/log"
# # Server configs are used to specify the configuration of TiKV Servers.
tikv_servers:
# # The ip address of the TiKV Server.
- host: 192.168.56.3
# # SSH port of the server.
# ssh_port: 22
# # TiKV Server communication port.
port: 20160
# # TiKV Server status API port.
status_port: 20180
# # TiKV Server deployment file, startup script, configuration file storage directory.
deploy_dir: "/tidb-deploy/tikv-20160"
# # TiKV Server data storage directory.
data_dir: "/tidb-data/tikv-20160"
# # TiKV Server log file storage directory.
log_dir: "/tidb-deploy/tikv-20160/log"
# # The following configs are used to overwrite the `server_configs.tikv` values.
config:
server.labels:
host: host1
- host: 192.168.56.3
# # SSH port of the server.
# ssh_port: 22
# # TiKV Server communication port.
port: 20161
# # TiKV Server status API port.
status_port: 20181
# # TiKV Server deployment file, startup script, configuration file storage directory.
deploy_dir: "/tidb-deploy/tikv-20161"
# # TiKV Server data storage directory.
data_dir: "/tidb-data/tikv-20161"
# # TiKV Server log file storage directory.
log_dir: "/tidb-deploy/tikv-20161/log"
# # The following configs are used to overwrite the `server_configs.tikv` values.
config:
server.labels:
host: host1
Where is the configuration wrong? Thank you.