Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tools/dm: update manage-task.md and add precheck.md (#931)
* tools/dm: update manage-task.md and add precheck.md Via: pingcap/docs-cn#1139 * dm: update the links related to precheck.md * dm: address lilian's comments
- Loading branch information
Showing
5 changed files
with
67 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
--- | ||
title: Precheck the upstream MySQL instance configuration | ||
summary: Use the precheck feature provided by DM to detect errors in the upstream MySQL instance configuration. | ||
category: tools | ||
--- | ||
|
||
# Precheck the upstream MySQL instance configuration | ||
|
||
This document introduces the precheck feature provided by DM. This feature is used to detect possible errors in the upstream MySQL instance configuration when the data replication task is started. | ||
|
||
## Command | ||
|
||
`check-task` allows you to precheck whether the upstream MySQL instance configuration satisfies the DM requirements. | ||
|
||
## Checking items | ||
|
||
Upstream and downstream database users must have the corresponding read and write privileges. DM checks the following privileges and configuration automatically while the data replication task is started: | ||
|
||
+ Database version | ||
|
||
- 5.5 < MySQL version < 5.8 | ||
- MariaDB version >= 10.1.2 | ||
|
||
+ MySQL binlog configuration | ||
|
||
- Whether the binlog is enabled (DM requires that the binlog must be enabled) | ||
- Whether `binlog_format=ROW` (DM only supports replication of the binlog in the ROW format) | ||
- Whether `binlog_row_image=FULL` (DM only supports `binlog_row_image=FULL`) | ||
|
||
+ The privileges of the upstream MySQL instance users | ||
|
||
MySQL users in DM configuration need to have the following privileges at least: | ||
|
||
- REPLICATION SLAVE | ||
- REPLICATION CLIENT | ||
- RELOAD | ||
- SELECT | ||
|
||
+ The compatibility of the upstream MySQL table schema | ||
|
||
TiDB differs from MySQL in compatibility in the following aspects: | ||
|
||
- TiDB does not support the foreign key. | ||
- [Character set compatibility differs](/sql/character-set-support.md). | ||
|
||
+ The consistency of the sharded tables in the multiple upstream MySQL instances | ||
|
||
+ The schema consistency of all sharded tables | ||
|
||
- Column size | ||
- Column name | ||
- Column position | ||
- Column type | ||
- Primary key | ||
- Unique index | ||
|
||
+ The conflict of the auto increment primary keys in the sharded tables | ||
|
||
- The check fails in the following two conditions: | ||
|
||
- The auto increment primary key exists in the sharded tables and its column type *is not* bigint. | ||
- The auto increment primary key exists in the sharded tables and its column type *is* bigint, but column mapping *is not* configured. | ||
|
||
- The check succeeds in other conditions except the two above. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters