Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.
Original topic: 开启tidb binlog 但 tidb_binlog库没有,查不到checkpoint
【TiDB Usage Environment】Production\Test Environment\POC
【TiDB Version】6.1.0
【Encountered Problem】
tidb_binlog is enabled, drainer is running normally, data is being synchronized to the downstream normally, but the tidb_binlog database cannot be found, and the checkpoint cannot be queried.
【Reproduction Path】What operations were performed to encounter the problem
【Problem Phenomenon and Impact】
Unable to query checkpoint.
The binlog has been found to be enabled, but the tidb_binlog database just won’t be generated automatically.
The entire operation: Execute scale-drainer.yaml through the tiup command to enable binlog;
Question: The tidb_binlog database is not automatically created. The documentation says that enabling binlog will create this database, but after enabling it, the database still does not exist. How can this database be automatically created in this situation?
You can check the drainer.toml parameter configuration
The current configuration of tiup cluster edit-config xxxx
is like this. Should syncer.to.checkpoint
be added?
drainer_servers:
- host: 2.2.2.2
ssh_port: 22
port: 8249
deploy_dir: /data/tidb-deploy/drainer-8249
data_dir: /data/tidb-data/drainer-8249
log_dir: /data/tidb-deploy/drainer-8249/log
commit_ts: -1
config:
syncer.db-type: mysql
syncer.to.host: 1.1.1.1
syncer.to.password: XXXXXX
syncer.to.port: 4000
syncer.to.user: root
arch: amd64
os: linux
syncer.to.checkpoint:
type: mysql
schema: tidb_binlog
You need to configure the MySQL connection information.