达梦8数据库迁移

type
status
date
slug
summary
tags
category
icon
password

1. MySQL/MariaDB 环境准备

1.1 安装和启动 MariaDB

1.2 创建测试数据库和用户

1.3 配置 MySQL 允许远程连接

2. 达梦数据库环境准备

2.1 启动达梦数据库

2.2 使用达梦命令行工具创建测试用户

3. 使用达梦迁移工具 (DTS)

3.1 启动达梦迁移工具

3.2 迁移过程中的关键配置

  1. 新建迁移工程
notion image
  1. 创建工程时命名为:mysql_to_DM8
notion image
  1. 创建迁移任务命名为:mysql_to_dmd
notion image
notion image
notion image
  1. 选择迁移方式:MySQL ===> DM
notion image
  1. 源数据库连接信息:
      • 主机名:localhost
      • 端口:3306
      • 用户名:migrate_user
      • 密码:Migrate@123
      • 数据库名:testdb
      notion image
  1. 目标数据库连接信息:
      • 主机名:192.168.183.200 (根据实际修改)
      • 端口:5236
      • 用户名:SYSDBA
      • 密码:SYSDBA (默认密码,如有修改请使用实际密码)
      notion image
      notion image
      notion image
      notion image
      notion image
      notion image

4. 验证迁移结果

4.1 使用达梦管理工具验证

notion image
notion image
notion image

4.2 使用命令行验证

5. 注意事项和故障排除

5.1 常见问题解决

5.2 数据类型映射注意事项

MySQL和达梦数据库有些数据类型需要特殊映射:
  • MySQL的TINYINT(1)映射为达梦的BIT
  • MySQL的DATETIME映射为达梦的TIMESTAMP
  • 字符串类型长度可能需要调整
 
Loading...