Skip to content

Commit 743fc24

Browse files
authored
sync-diff-inspector: update required privilege for sync-diff-inspector (pingcap#21160) (pingcap#21173)
1 parent 1449266 commit 743fc24

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

sync-diff-inspector/sync-diff-inspector-overview.md

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,15 @@ This guide introduces the key features of sync-diff-inspector and describes how
3737

3838
## Database privileges for sync-diff-inspector
3939

40-
sync-diff-inspector needs to obtain the information of table schema and to query data. The required database privileges are as follows:
41-
42-
* Upstream database
43-
- `SELECT` (checks data for comparison)
44-
- `SHOW_DATABASES` (views database name)
45-
- `RELOAD` (views table schema)
46-
* Downstream database
47-
- `SELECT` (checks data for comparison)
48-
- `SHOW_DATABASES` (views database name)
49-
- `RELOAD` (views table schema)
40+
To access table schemas and query data, sync-diff-inspector requires specific database privileges. Grant the following privileges on both the upstream and downstream databases:
41+
42+
- `SELECT`: required to compare data.
43+
- `RELOAD`: required to view table schemas.
44+
45+
> **Note**:
46+
>
47+
> - **DO NOT** grant the [`SHOW DATABASES`](/sql-statements/sql-statement-show-databases.md) privilege on all databases (`*.*`). Otherwise, sync-diff-inspector will attempt to access inaccessible databases, which causes errors.
48+
> - For MySQL data sources, ensure that the [`skip_show_database`](https://dev.mysql.com/doc/refman/8.4/en/server-system-variables.html#sysvar_skip_show_database) system variable is set to `OFF`. If this variable is set to `ON`, the check might fail.
5049

5150
## Configuration file description
5251

0 commit comments

Comments
 (0)