各位大神,请教一下,在现有的集群上,启用binlog,tidb无法启动,谢谢

  • 【TiDB 版本】:3.0
  • 【问题描述】:在现有的集群上,启用binlog,tidb无法启动,停止在wait until the tidb port is up。查看tidb_stderr.log,发现报错:invalid config txn-total-size-limit should be less than 104857600 with binlog enabled,但是没有找到这项配置在哪个配置文件里。也不知道是否这个错误引起tidb无法启动,谢谢。
  1. txn-total-size-limit 在 TiDB 的配置 tidb.toml 里配置
  2. txn-total-size-limit 建议改小, binglog 确实有大小限制

你好,这个配置项是放到哪个节点下,我在这个配置文件的默认配置项里没有找着这个,谢谢

# TiDB Configuration.

compatible-kill-query = false
host = "0.0.0.0"

lease = "45s"
oom-action = "log"
socket = ""
store = "tikv"
token-limit = 1000

[log]
expensive-threshold = 10000
level = "info"
slow-threshold = 300

[security]
cluster-ssl-ca = ""
cluster-ssl-cert = ""
cluster-ssl-key = ""

[status]
metrics-addr = ""
metrics-interval = 15
status-host = "0.0.0.0"
status-port = 10080

[performance]
max-procs = 0
stats-lease = "3s"
stmt-count-limit = 5000

[proxy-protocol]

[prepared-plan-cache]
capacity = 100
enabled = false
memory-guard-ratio = 0.1

[opentracing]
enable = false
rpc-metrics = false

[opentracing.reporter]
buffer-flush-interval = 0
local-agent-host-port = ""
log-spans = false
queue-size = 0

[opentracing.sampler]
max-operations = 0
param = 1.0
sampling-refresh-interval = 0
sampling-server-url = ""
type = "const"

[tikv-client]
commit-timeout = "41s"
grpc-connection-count = 4
grpc-keepalive-time = 10
grpc-keepalive-timeout = 3

[txn-local-latches]

[binlog]
ignore-error = false
write-timeout = "15s"

[pessimistic-txn]
enable = true
max-retry-count = 256

这个配置项,在每一个 tidb-server 上都有,请问你提供的配置文件是正在运行节点上的配置文件吗?

你好,请问,这个“配置文件的默认配置项”是报错集群使用的配置吗?请确认下是否每个 TiDB server 的配置文件都没有配置过 txn-total-size-limit。如果都没有配置过,应该是不符合预期的。我们会尝试复现。

是的,我是从运行目录的/conf/tidb.toml文件拷贝出来的,我是3.0版的是版本不一样吗

我在tidb的目录里查找了,都没有这项配置

好。请提供一下 tidb-server 的详细版本。可以 ./tidb-server -V 来查看。

Release Version: v4.0.0-alpha-1219-g510c36d4c
Git Commit Hash: 510c36d4cb776ea47034b9ef2985beeb91093481
Git Branch: master
UTC Build Time: 2019-12-22 01:17:12
GoVersion: go1.13
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false

版本是 4.0.0-alpha,建议直接在配置文件中加上 txn-total-size-limit 配置项,并将值配置小于 100MB 测试一下

好谢谢,配置到哪个节点,[performance]下吗?

对,performance 节点下面。参考下这个:

  1. 有部署 binlog 服务相关的 tidb 都需要配置
  2. txn-total-size-limit 是独立的配置项,放在 [performance] 下面就 OK

好,谢谢,我试一下

感谢提问,谢谢!

此话题已在最后回复的 1 分钟后被自动关闭。不再允许新回复。