DM does not support multi-database migration?

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

Original topic: DM不支持多库迁移?

| username: Clover

【TiDB Usage Environment】Poc
【TiDB Version】7.3

Migration source “clover”, “db01” these two full databases.

block-allow-list:
  bw-rule-1:                              # Name
    do-dbs: ["clover", "db01"]

Writing one database in do-dbs: [“clover”, “db01”] works, but multiple databases do not. No errors, but the target has no data.

| username: 大飞哥online | Original post link

| username: 大飞哥online | Original post link

You can check the official documentation. I’m also looking at it to see if there are any limitations or anything.

| username: 大飞哥online | Original post link

It seems like one task per database.

| username: Clover | Original post link

The documentation says it is possible, but the experimental results show it is not.

| username: 大飞哥online | Original post link

It says here that it is possible. I haven’t tried it, don’t have the conditions, haha.

| username: 大飞哥online | Original post link

Wait a moment, let’s see if there are any experienced users who know about this. I’ll be waiting.

| username: 大飞哥online | Original post link

Is there any information output in the logs?

| username: Clover | Original post link

It is possible to split by database, which I understand is one solution. The implication is that it is also possible not to split, with one TASK for multiple databases, as per the documentation. However, the experiment did not pass.

| username: Clover | Original post link

Set up an environment. Tiup playground is super simple.

| username: Clover | Original post link

No.

| username: 大飞哥online | Original post link

What you wrote is incorrect.

| username: 大飞哥online | Original post link

The information inside do-dbs needs to correspond with the db-name below.

| username: TiDB_C罗 | Original post link

Take a look at this introduction TiDB Data Migration 黑白名单过滤 | PingCAP 文档中心
First, enter dbs to determine tables.
According to your requirements, it should be written like this:

block-allow-list: 
  bw-rule:
    do-dbs: ["clover", "db01", "test"]
    do-tables:
    - db-name: "test"
      tbl-name: "k"

The entire clover and db01 databases are synchronized because there are no table filtering rules below. Only the k table in the test database is synchronized.

| username: TiDB_C罗 | Original post link

It is suggested that the official release a corresponding testing tool to verify whether the set rules meet expectations. Alertmanager has a corresponding testing environment for routing rules.

| username: Clover | Original post link

Tried it, still the same.

| username: redgame | Original post link

Support.

| username: Fly-bird | Original post link

Write separately.

| username: system | Original post link

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