diff --git a/dm/dm-precheck.md b/dm/dm-precheck.md index cea13878f7674..27716a0a7c288 100644 --- a/dm/dm-precheck.md +++ b/dm/dm-precheck.md @@ -139,6 +139,16 @@ For the incremental data migration mode (`task-mode: incremental`), in addition - Check whether `binlog_transaction_compression=OFF` is configured (DM does not support transaction compression). - If `binlog_do_db` or `binlog_ignore_db` is configured, check whether the database tables to be migrated meet the conditions of `binlog_do_db` and `binlog_ignore_db`. +* (Mandatory) MariaDB binlog configuration + + - Check whether binlog is enabled (required by DM). + - Check whether `binlog_legacy_event_pos` is set to `ON`. + - Check whether `binlog_format=ROW` is configured (DM only supports the migration of binlog in the ROW format). + - Check whether `binlog_row_image=FULL` is configured (DM only supports `binlog_row_image=FULL`). + - If `binlog_do_db` or `binlog_ignore_db` is configured, check whether the database tables to be migrated meet the conditions of `binlog_do_db` and `binlog_ignore_db`. + - Check whether `binlog_annotate_row_events` is set to `OFF`. + - Check whether `log_bin_compress` is set to `OFF`. + * (Mandatory) Check if the upstream database is in an [Online-DDL](/dm/feature-online-ddl.md) process (in which the `ghost` table is created but the `rename` phase is not executed yet). If the upstream is in the online-DDL process, the precheck returns an error. In this case, wait until the DDL to complete and retry. ### Check items for full and incremental data migration diff --git a/migrate-from-mariadb.md b/migrate-from-mariadb.md index ac345afec9235..48a2bde211224 100644 --- a/migrate-from-mariadb.md +++ b/migrate-from-mariadb.md @@ -294,7 +294,7 @@ To use DM, you need to deploy a set of DM services either with a [TiUP cluster]( ### Step 1. Prepare -Make sure that binlogs are enabled on MariaDB and that the `binlog_format` is set to `ROW`. It is also recommended to set `binlog_annotate_row_events=OFF` and `log_bin_compress=OFF`. +Enable binlog on MariaDB and set `binlog_format=ROW`, `binlog_row_image=FULL`, and `binlog_legacy_event_pos=ON`. Also set `binlog_annotate_row_events=OFF` and `log_bin_compress=OFF`. You also need an account with the `SUPER` permission or with the `BINLOG MONITOR` and `REPLICATION MASTER ADMIN` permissions. This account also needs read permission for the schemas you are going to migrate.