Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

[TiDB Usage Environment] Synchronize CDC tasks from pre-production environment to test environment
[TiDB Version] v5.4.0
[Reproduction Path] # tiup cdc cli changefeed create --pd=“http://10.3.xx.88:2379” --sink-uri=“mysql://root:9CMv3k%a$6wyD=586@10.3.xx.99:4000/" --changefeed-id=“bj_pre_to_test_01” --sort-engine=“unified” --config=“./bj_pre_to_test_01.toml” --start-ts=‘439311187320766467’
[Encountered Problem: Problem Phenomenon and Impact]
Error reported as follows:
Error: [CDC:ErrSinkURIInvalid]sink uri invalid: parse "mysql://root:9CMv3k%a$6wyD=581@10.3.xx.99:4000/”: invalid URL escape “%a$”
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
–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:ErrSinkURIInvalid]sink uri invalid: parse “mysql://root:9CMv3k%a$6wyD=5*86@10.3.xx.99:4000/”: invalid URL escape “%a$”
[Resource Configuration]
[Attachments: Screenshots/Logs/Monitoring]