Sync-diff-inspector Error

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

Original topic: sync-diff-inspector 报错

| username: 烂番薯0

After completing the task migration based on DM, I used sync-diff-inspector for data verification and repair, but an error occurred.

| username: 裤衩儿飞上天 | Original post link

What error is being reported?

| username: 烂番薯0 | Original post link

The error reported is: failed to init Task: [code=20053:class=config:scope=internal:level=medium], Message: invalid load mode ‘logical’, Workaround: Please choose a valid value in [‘sql’, ‘loader’].

| username: 裤衩儿飞上天 | Original post link

  1. Is the upstream MySQL and the downstream TiDB?
  2. Is data being written to both upstream and downstream during the verification process?
| username: 烂番薯0 | Original post link

The upstream is MySQL, and there is no data being written.

| username: 裤衩儿飞上天 | Original post link

Is this an error from the dm task or sync-diff-inspector?

For the usage limitations of sync-diff-inspector, refer to: sync-diff-inspector User Documentation | PingCAP Documentation Center

| username: 烂番薯0 | Original post link

Hmm, this is an error from sync-diff-inspector. I imported data from MySQL to TiDB using DM, but some data was lost in TiDB and some data is incorrect. I want to use this to fix the data, but I don’t know how to proceed…

| username: buddyyuan | Original post link

After setting this, there will be a “fix” directory, which contains the SQL statements for the fixes.

| username: liuis | Original post link

Why can’t I find this error in the source code?

| username: 烂番薯0 | Original post link

I have set it up now, but there is an error message.

| username: 烂番薯0 | Original post link

I don’t know if this error is due to a problem with the configuration file.

| username: 胡杨树旁 | Original post link

Looking at this error, it says there is an issue in the configuration file, asking to choose either sql or loader. Is this error from sync_diff?

| username: 胡杨树旁 | Original post link

Is this the entire configuration file?

| username: 烂番薯0 | Original post link

Yes, that’s right. I couldn’t find that option to choose the configuration on the official website.

| username: 烂番薯0 | Original post link

Yes, that’s right.

| username: 胡杨树旁 | Original post link

Based on DM data verification, I haven’t used it before. If the upstream is MySQL and the downstream is TiDB, and the data is static, you can try using this configuration file writing method.

| username: system | Original post link

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.