Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: TICDC创建changefeed报错
[TiDB Usage Environment] Production Environment / Testing / Poc
[TiDB Version]
[Reproduction Path] What operations were performed to encounter the issue
[Encountered Issue: Problem Phenomenon and Impact]
TICDC reports an error when creating a changefeed, with the downstream being PerconaServe-5.7
[root@xxxx 3308_test]# tiup cdc cli changefeed create --sink-uri="mysql://ticdc:ticdc@10.122.132.203:3308/?time-zone=CST&worker-count=8&max-txn-row=2000&transaction-atomicity=table" --pd="http://10.122.132.203:2379" --changefeed-id="simple-replication-task" --sort-engine="unified"
tiup is checking updates for component cdc ...
A new version of cdc is available:
The latest version: v6.4.0
Local installed version: v6.1.0
Update current component: tiup update cdc
Update all components: tiup update --all
Starting component `cdc`: /root/.tiup/components/cdc/v6.1.0/cdc cli changefeed create --sink-uri=mysql://ticdc:ticdc@10.122.132.203:3308/?time-zone=CST&worker-count=8&max-txn-row=2000&transaction-atomicity=table --pd=http://10.122.132.203:2379 --changefeed-id=simple-replication-task --sort-engine=unified
Error: [CDC:ErrMySQLInvalidConfig]MySQL config invalid: unknown time zone CST
Usage:
cdc cli changefeed create [flags]
Flags:
-c, --changefeed-id string Replication task (changefeed) ID
--config string Path of the configuration file
--cyclic-filter-replica-ids uints (Experimental) Cyclic replication filter replica ID of changefeed (default [])
--cyclic-replica-id uint (Experimental) Cyclic replication replica ID of changefeed
--cyclic-sync-ddl (Experimental) Cyclic replication sync DDL of changefeed (default true)
--disable-gc-check Disable GC safe point check
-h, --help help for create
--no-confirm Don't ask user whether to ignore ineligible table
--opts key=value Extra options, in the key=value format
--schema-registry string Avro Schema Registry URI
--sink-uri string sink uri
--sort-engine string sort engine used for data sort (default "unified")
--start-ts uint Start ts of changefeed
--sync-interval duration (Experimental) Set the interval for syncpoint in replication(default 10min) (default 10m0s)
--sync-point (Experimental) Set and Record syncpoint in replication(default off)
--target-ts uint Target ts of changefeed
--tz string timezone used when checking sink uri (changefeed timezone is determined by cdc server) (default "SYSTEM")
Global Flags:
--ca string CA certificate path for TLS connection
--cert string Certificate path for TLS connection
-i, --interact Run cdc cli with readline
--key string Private key path for TLS connection
--log-level string log level (etc: debug|info|warn|error) (default "warn")
--pd string PD address, use ',' to separate multiple PDs (default "http://127.0.0.1:2379")
[CDC:ErrMySQLInvalidConfig]MySQL config invalid: unknown time zone CST
The upstream TiDB time zone configuration is as follows:
mysql> show variables like '%time_zone%';
+------------------+---------------+
| Variable_name | Value |
+------------------+---------------+
| system_time_zone | Asia/Shanghai |
| time_zone | SYSTEM |
+------------------+---------------+
2 rows in set (0.00 sec)
mysql>
The downstream MySQL time zone configuration is as follows:
mysql>
mysql> show variables like '%time_zone%';
+------------------+--------+
| Variable_name | Value |
+------------------+--------+
| system_time_zone | CST |
| time_zone | SYSTEM |
+------------------+--------+
2 rows in set (0.00 sec)
mysql>
[Resource Configuration]
[Attachments: Screenshots/Logs/Monitoring]