Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: 本地单机模拟生产环境集群部署,启动集群,TIDB报错

[TiDB Usage Environment] Test
[TiDB Version] v6.4.0
[Reproduction Path] Normal deployment according to the official deployment documentation
[Encountered Issue: Problem Phenomenon and Impact]
When starting the cluster, an exception is thrown when starting TiDB, indicating a startup failure.
[Resource Configuration]
Deepin system, disk and memory space not checked, but can ensure sufficient space.
[Attachment: Screenshot/Log/Monitoring]
[2022/12/29 11:51:58.086 +08:00] [INFO] [cpuprofile.go:113] [“parallel cpu profiler started”]
[2022/12/29 11:51:58.087 +08:00] [INFO] [printer.go:34] [“Welcome to TiDB.”] [“Release Version”=v6.4.0] [Edition=Community] [“Git Commit Hash”=cf36a9ce2fe1039db3cf3444d51930b887df18a1] [“Git Branch”=heads/refs/tags/v6.4.0] [“UTC Build Time”=“2022-11-13 05:25:30”] [GoVersion=go1.19.2] [“Race Enabled”=false] [“Check Table Before Drop”=false] [“TiKV Min Version”=6.2.0-alpha]
[2022/12/29 11:51:58.087 +08:00] [INFO] [printer.go:48] [“loaded config”] [config=“{"host":"0.0.0.0","advertise-address":"192.168.0.3","port":4000,"cors":"","store":"tikv","path":"192.168.0.3:2379","socket":"/tmp/tidb-4000.sock","lease":"45s","split-table":true,"token-limit":1000,"temp-dir":"/tmp/tidb","tmp-storage-path":"/tmp/1001_tidb/MC4wLjAuMDo0MDAwLzAuMC4wLjA6MTAwODA=/tmp-storage","tmp-storage-quota":-1,"server-version":"","version-comment":"","tidb-edition":"","tidb-release-version":"","log":{"level":"info","format":"text","disable-timestamp":null,"enable-timestamp":null,"disable-error-stack":null,"enable-error-stack":null,"file":{"filename":"/tidb-deploy/tidb-4000/log/tidb.log","max-size":300,"max-days":0,"max-backups":0},"slow-query-file":"/tidb-deploy/tidb-4000/log/tidb_slow_query.log","expensive-threshold":10000,"query-log-max-len":4096,"enable-slow-log":true,"slow-threshold":300,"record-plan-in-slow-log":1},"instance":{"tidb_general_log":false,"tidb_pprof_sql_cpu":false,"ddl_slow_threshold":300,"tidb_expensive_query_time_threshold":60,"tidb_enable_slow_log":true,"tidb_slow_log_threshold":300,"tidb_record_plan_in_slow_log":1,"tidb_check_mb4_value_in_utf8":true,"tidb_force_priority":"NO_PRIORITY","tidb_memory_usage_alarm_ratio":0.8,"tidb_enable_collect_execution_info":true,"plugin_dir":"/data/deploy/plugin","plugin_load":"","max_connections":0,"tidb_enable_ddl":true,"tidb_rc_read_check_ts":false},"security":{"skip-grant-table":false,"ssl-ca":"","ssl-cert":"","ssl-key":"","cluster-ssl-ca":"","cluster-ssl-cert":"","cluster-ssl-key":"","cluster-verify-cn":null,"session-token-signing-cert":"","session-token-signing-key":"","spilled-file-encryption-method":"plaintext","enable-sem":false,"auto-tls":false,"tls-version":"","rsa-key-size":4096,"secure-bootstrap":false,"auth-token-jwks":"","auth-token-refresh-interval":"1h0m0s"},"status":{"status-host":"0.0.0.0","metrics-addr":"","status-port":10080,"metrics-interval":15,"report-status":true,"record-db-qps":false,"grpc-keepalive-time":10,"grpc-keepalive-timeout":3,"grpc-concurrent-streams":1024,"grpc-initial-window-size":2097152,"grpc-max-send-msg-size":2147483647},"performance":{"max-procs":0,"max-memory":0,"server-memory-quota":0,"stats-lease":"3s","stmt-count-limit":5000,"pseudo-estimate-ratio":0.8,"bind-info-lease":"3s","txn-entry-size-limit":6291456,"txn-total-size-limit":104857600,"tcp-keep-alive":true,"tcp-no-delay":true,"cross-join":true,"distinct-agg-push-down":false,"projection-push-down":false,"max-txn-ttl":3600000,"index-usage-sync-lease":"0s","plan-replayer-gc-lease":"10m","gogc":100,"enforce-mpp":false,"stats-load-concurrency":5,"stats-load-queue-size":1000,"analyze-partition-concurrency-quota":16,"enable-stats-cache-mem-quota":false,"committer-concurrency":128,"run-auto-analyze":true,"force-priority":"NO_PRIORITY","memory-usage-alarm-ratio":0.8,"enable-load-fmsketch":false},"prepared-plan-cache":{"enabled":true,"capacity":100,"memory-guard-ratio":0.1},"opentracing":{"enable":false,"rpc-metrics":false,"sampler":{"type":"const","param":1,"sampling-server-url":"","max-operations":0,"sampling-refresh-interval":0},"reporter":{"queue-size":0,"buffer-flush-interval":0,"log-spans":false,"local-agent-host-port":""}},"proxy-protocol":{"networks":"","header-timeout":5},"pd-client":{"pd-server-timeout":3},"tikv-client":{"grpc-connection-count":4,"grpc-keepalive-time":10,"grpc-keepalive-timeout":3,"grpc-compression-type":"none","commit-timeout":"41s","async-commit":{"keys-limit":256,"total-key-size-limit":4096,"safe-window":2000000000,"allowed-clock-drift":500000000},"max-batch-size":128,"overload-threshold":200,"max-batch-wait-time":0,"batch-wait-size":8,"enable-chunk-rpc":true,"region-cache-ttl":600,"store-limit":0,"store-liveness-timeout":"1s","copr-cache":{"capacity-mb":1000},"ttl-refreshed-txn-size":33554432,"resolve-lock-lite-threshold":16},"binlog":{"enable":false,"ignore-error":false,"write-timeout":"15s","binlog-socket":"","strategy":"range"},"compatible-kill-query":false,"pessimistic-txn":{"max-retry-count":256,"deadlock-history-capacity":10,"deadlock-history-collect-retryable":false,"pessimistic-auto-commit":false,"constraint-check-in-place-pessimistic":true},"max-index-length":3072,"index-limit":64,"table-column-count-limit":1017,"graceful-wait-before-shutdown":0,"alter-primary-key":false,"treat-old-version-utf8-as-utf8mb4":true,"enable-table-lock":false,"delay-clean-table-lock":0,"split-region-max-num":1000,"top-sql":{"receiver-address":""},"repair-mode":false,"repair-table-list":,"isolation-read":{"engines":["tikv","tiflash","tidb"]},"new_collations_enabled_on_first-bootstrap":true,"experimental":{"allow-expression-index":false},"skip-register-to-dashboard":false,"enable-telemetry":true,"labels":{},"enable-global-index":false,"deprecate-integer-display-length":false,"enable-enum-length-limit":true,"stores-refresh-interval":60,"enable-tcp4-only":false,"enable-forwarding":false,"max-ballast-object-size":0,"ballast-object-size":0,"transaction-summary":{"transaction-summary-capacity":500,"transaction-id-digest-min-duration":2147483647},"enable-global-kill":true,"enable-batch-dml":false,"mem-quota-query":1073741824,"oom-action":"cancel","oom-use-tmp-storage":true,"check-mb4-value-in-utf8":true,"enable-collect-execution-info":true,"plugin":{"dir":"/data/deploy/plugin","load":""},"max-server-connections":0,"run-ddl":true,"tidb-max-reuse-chunk":64,"tidb-max-reuse-column":256}”]
[2022/12/29 11:51:58.087 +08:00] [INFO] [global.go:34] [“disable Prometheus push client”]
[2022/12/29 11:51:58.087 +08:00] [INFO] [store.go:75] [“new store”] [path=tikv://192.168.0.3:2379]
[2022/12/29 11:51:58.087 +08:00] [INFO] [global.go:34] [“[pd] create pd client with endpoints”] [pd-address=“[192.168.0.3:2379]”]
[2022/12/29 11:51:58.087 +08:00] [INFO] [systime_mon.go:26] [“start system time monitor”]
[2022/12/29 11:51:58.089 +08:00] [INFO] [global.go:34] [“[pd] switch leader”] [new-leader=http://192.168.0.3:2379] [old-leader=]
[2022/12/29 11:51:58.089 +08:00] [INFO] [global.go:34] [“[pd] init cluster id”] [cluster-id=7182393733391509280]
[2022/12/29 11:51:58.089 +08:00] [INFO] [global.go:34] [“[pd] tso dispatcher created”] [dc-location=global]
[2022/12/29 11:51:58.090 +08:00] [INFO] [store.go:81] [“new store with retry success”]
[2022/12/29 11:52:12.696 +08:00] [INFO] [tidb.go:77] [“new domain”] [store=tikv-7182393733391509280] [“ddl lease”=45s] [“stats lease”=3s] [“index usage sync lease”=0s]
[2022/12/29 11:52:12.775 +08:00] [INFO] [domain.go:2098] [acquireServerID] [serverID=1460877] [“lease id”=11eb855c01f0ae87]
[2022/12/29 11:52:12.829 +08:00] [WARN] [info.go:245] [“init TiFlashReplicaManager”] [“pd addrs”=“[192.168.0.3:2379]”]
[2022/12/29 11:52:14.489 +08:00] [INFO] [domain.go:214] [“full load InfoSchema success”] [currentSchemaVersion=0] [neededSchemaVersion=18] [“start time”=1.593367529s]
[2022/12/29 11:52:14.563 +08:00] [INFO] [domain.go:481] [“full load and reset schema validator”]
[2022/12/29 11:52:14.563 +08:00] [INFO] [ddl.go:701] [“[ddl] start DDL”] [ID=dd676362-15dc-4c7d-a2a1-1db90c922f7b] [runWorker=true]
[2022/12/29 11:52:14.563 +08:00] [INFO] [ddl.go:647] [“[ddl] start delRangeManager OK”] [“is a emulator”=false]
[2022/12/29 11:52:14.563 +08:00] [INFO] [manager.go:151] [“start campaign owner”] [ownerInfo=“[ddl] /tidb/ddl/fg/owner”]
[2022/12/29 11:52:14.563 +08:00] [INFO] [ddl_worker.go:171] [“[ddl] start DDL worker”] [worker=“worker 2, tp add index”]
[2022/12/29 11:52:14.563 +08:00] [INFO] [ddl_worker.go:171] [“[ddl] start DDL worker”] [worker=“worker 1, tp general”]
[2022/12/29 11:52:14.571 +08:00] [INFO] [env.go:101] [“[ddl-ingest] the lightning sorted dir”] [“data path:”=/tmp/tidb/tmp_ddl-4000]
[2022/12/29 11:52:14.571 +08:00] [INFO] [env.go:68] [“[ddl-ingest] init global lightning backend environment finished”] [“memory limitation”=2147483648] [“sort path disk quota”=14206685184] [“max open file number”=1000000] [“lightning is initialized”=true]
[2022/12/29 11:52:14.571 +08:00] [INFO] [global.go:34] [“begin advancer daemon”] [daemon-id=LogBackup::Advancer]
[2022/12/29 11:52:14.571 +08:00] [INFO] [manager.go:151] [“start campaign owner”] [ownerInfo=“[log-backup] /tidb/br-stream/owner”]
[2022/12/29 11:52:14.605 +08:00] [INFO] [global.go:34] [“begin running daemon”] [id=24826597-c74f-4763-836a-bd423e5a25da] [daemon-id=LogBackup::Advancer]
[2022/12/29 11:52:16.572 +08:00] [INFO] [info.go:1085] [SetTiFlashGroupConfig]
[2022/12/29 11:52:57.321 +08:00] [INFO] [manager.go:296] [“get owner”] [“owner info”=“[log-backup] /tidb/br-stream/owner ownerManager 24826597-c74f-4763-836a-bd423e5a25da”] [ownerID=24826597-c74f-4763-836a-bd423e5a25da]
[2022/12/29 11:52:57.321 +08:00] [INFO] [manager.go:296] [“get owner”] [“owner info”=“[ddl] /tidb/ddl/fg/owner ownerManager dd676362-15dc-4c7d-a2a1-1db90c922f7b”] [ownerID=dd676362-15dc-4c7d-a2a1-1db90c922f7b]
[2022/12/29 11:52:57.506 +08:00] [INFO] [session.go:3313] [“CRUCIAL OPERATION”] [conn=0] [schemaVersion=18] [cur_db=mysql] [sql=“CREATE DATABASE IF NOT EXISTS test”] [user=]
[2022/12/29 11:52:57.506 +08:00] [INFO] [session.go:3313] [“CRUCIAL OPERATION”] [conn=0] [schemaVersion=18] [cur_db=mysql] [sql=“CREATE DATABASE IF NOT EXISTS mysql
”] [user=]
[2022/12/29 11:52:57.506 +08:00] [INFO] [session.go:3313] [“CRUCIAL OPERATION”] [conn=0] [schemaVersion=18] [cur_db=mysql] [sql="CREATE TABLE IF NOT EXISTS mysql.user (\n\t\tHost\t\t\t\t\tCHAR(255),\n\t\tUser\t\t\t\t\tCHAR(32),\n\t\tauthentication_string\tTEXT,\n\t\tplugin\t\t\t\t\tCHAR(64),\n\t\tSelect_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tInsert_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tUpdate_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tDelete_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tCreate_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tDrop_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tProcess_priv\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tGrant_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tReferences_priv\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tAlter_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tShow_db_priv\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tSuper_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tCreate_tmp_table_priv\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tLock_tables_priv\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tExecute_priv\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tCreate_view_priv\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tShow_view_priv\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tCreate_routine_priv\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tAlter_routine_priv\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tIndex_priv\t\t\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\tCreate_user_priv\t\tENUM(‘N’,‘Y’) NOT NULL DEFAULT ‘N’,\n\t\t