关于tikv的调试

[root@tidb1 bin]# ./pd-server --help
Placement Driver server

Usage:
  pd-server [flags]
  pd-server [command]

Available Commands:
  help        Help about any command
  services    Run services, for example, tso, resource_manager

Flags:
      --advertise-client-urls string   advertise urls for client traffic (default '${client-urls}')
      --advertise-peer-urls string     advertise urls for peer traffic (default '${peer-urls}')
      --cacert string                  path of file that contains list of trusted TLS CAs
      --cert string                    path of file that contains X509 certificate in PEM format
      --client-urls string             urls for client traffic
      --config string                  config file
      --config-check                   check config file validity and exit
      --data-dir string                path to the data directory (default 'default.${name}')
      --force-new-cluster              force to create a new one-member cluster
  -h, --help                           help for pd-server
      --initial-cluster string         initial cluster configuration for bootstrapping, e,g. pd=http://127.0.0.1:2380
      --join string                    join to an existing cluster (usage: cluster's '${advertise-client-urls}'
      --key string                     path of file that contains X509 key in PEM format
      --log-file string                log file path
  -L, --log-level string               log level: debug, info, warn, error, fatal (default 'info') (default "info")
      --metrics-addr string            prometheus pushgateway address, leaves it empty will disable prometheus push
      --name string                    human-readable name for this pd member
      --peer-urls string               urls for peer traffic
  -V, --version                        print version information and exit

Use "pd-server [command] --help" for more information about a command.

只要你编译出来的pd-server能看到下面这个参数
--config string config file
就应该能通过这个参数设置pd.toml文件

完整的启动参数进程参数,我也给你一个,供参考:

bin/pd-server --name=pd-172.21.16.10-2379 --client-urls=http://0.0.0.0:2379 --advertise-client-urls=http://172.21.16.10:2379 --peer-urls=http://0.0.0.0:2380 --advertise-peer-urls=http://172.21.16.10:2380 --data-dir=/tidb-data/pd-2379 --initial-cluster=pd-172.21.16.10-2379=http://172.21.16.10:2380,pd-172.21.16.17-2379=http://172.21.16.17:2380,pd-172.21.0.143-2379=http://172.21.0.143:2380 --config=conf/pd.toml --log-file=/tidb-deploy/pd-2379/log/pd.log