RDS Best Practices — Fast and Stable Migration to RDS

本文涉及的产品
RDS SQL Server Serverless,2-4RCU 50GB 3个月
推荐场景:
云数据库 RDS SQL Server,基础系列 2核4GB
RDS MySQL Serverless 基础系列,0.5-2RCU 50GB
简介: In this article, I will explain how to perform fast and stable migration to RDS.

Database_tuning_practices

In this article, I will explain how to perform fast and stable migration to RDS.

Data migration to RDS can be started once the purchase has been made. When the RDS begins providing services, users can only dump user databases as a SQL file and then source the SQL file to RDS: migrating data to RDS–MySQL by using the MySQL dump tool and migrating data to RDS–SQL Server by using the SQL Server client tool. These two methods are the simplest, but also have many limitations:

The user's database is too big and the logical SQL import method is slow, causing significant downtime.

Too many errors occur during import, or the import process is interrupted. Therefore, the import needs be started over again.

The user's database must still provide services during migration to RDS.

A lot of users shy away from moving their services to the cloud because of data migration, making it the only thing that stands between them and RDS. However, as Confucius once said, "a craftsman who wishes to do his work well must first sharpen his tools". In order to help users better access the cloud, RDS has improved the existing RDS migration methods, aiming at helping users perform fast and stable migration to RDS. Improved MySQL and SQL Server migration tools are separately provided:

The MySQL migration tool supports online migration where users can migrate data to RDS without interrupting service.

The SQL Server migration tool uploads users' physical backups to an FTP and then restores the physical backups to RDS, which improves migration speed.

These two tools have been integrated in the RDS console. Refer to the official guide for RDS in the documentation center.

When most users look at a console, they can only see a black box. It's not uncommon to see users raising tickets through the console regarding the principles of. Here I will roughly describe the implementation process for each tool:

Principle of MySQL Online Migration:

Step 1: Pre-check, mainly used to verify whether the network is connected and check the account and environment.

Step 2: Full backup, where all user data will be dumped and then restored to RDS.

Step 3: Incremental migration, where binlog applications generated during full backup and the following steps will all be parsed to RDS.

Step 4: Switching, where the RDS data has completely overtaken the user's database and switching can begin.

The MySQL online migration tool has some limitations, however. For example:

• MySQL 5.0 only supports full migration, and does not support incremental migration;

• Migration with MySQL 5.6 is not supported, as the storage process and trigger migration are not supported;

• During migration, incremental migration will fail if ddl occurs.

Principle of SQL Server Tool Migration:

Step 1: Physical backup is performed on local databases.

Step 2: The backups are uploaded to an FTP server provided by RDS (the FTP address supports uploading via both a private network and a public network).

Step 3: After RDS scans and verifies user's uploaded backups, the backups are restored to the RDS.

Step 4: The user switches the application to RDS.

Because SQL Server hasn't opened the log interface, RDS currently cannot support online migration. RDS currently does not support importing from the master database.

I hope that this article will help you in your journey with RDS.

相关实践学习
如何在云端创建MySQL数据库
开始实验后,系统会自动创建一台自建MySQL的 源数据库 ECS 实例和一台 目标数据库 RDS。
全面了解阿里云能为你做什么
阿里云在全球各地部署高效节能的绿色数据中心,利用清洁计算为万物互联的新世界提供源源不断的能源动力,目前开服的区域包括中国(华北、华东、华南、香港)、新加坡、美国(美东、美西)、欧洲、中东、澳大利亚、日本。目前阿里云的产品涵盖弹性计算、数据库、存储与CDN、分析与搜索、云通信、网络、管理与监控、应用服务、互联网中间件、移动服务、视频服务等。通过本课程,来了解阿里云能够为你的业务带来哪些帮助     相关的阿里云产品:云服务器ECS 云服务器 ECS(Elastic Compute Service)是一种弹性可伸缩的计算服务,助您降低 IT 成本,提升运维效率,使您更专注于核心业务创新。产品详情: https://www.aliyun.com/product/ecs
目录
相关文章
|
关系型数据库 PostgreSQL RDS
Partitioned Index - Alibaba Cloud RDS PostgreSQL Best Practices
When should you partition a table in your database? Learn how to split tables with partial index.
2081 0
|
SQL 关系型数据库 C语言
Full-text Search Index Optimization - Alibaba Cloud RDS PostgreSQL Best Practices
Will indexes be used in full-text searches that do not contain a certain keyword? Learn more about GIN, Generalized Inverted Index.
3957 0
|
SQL 机器学习/深度学习 关系型数据库
RDS SQL Server– Best Practices of Execution Plan Cache for Missing Indexes
Execution plan cache is a significant part of SQL Server memory management. It can reveal to you how the execution of a query will occur, or how query execution took place.
2738 0
|
17天前
|
NoSQL 关系型数据库 MySQL
微服务架构下的数据库选择:MySQL、PostgreSQL 还是 NoSQL?
在微服务架构中,数据库的选择至关重要。不同类型的数据库适用于不同的需求和场景。在本文章中,我们将深入探讨传统的关系型数据库(如 MySQL 和 PostgreSQL)与现代 NoSQL 数据库的优劣势,并分析在微服务架构下的最佳实践。
|
19天前
|
存储 SQL 关系型数据库
使用MySQL Workbench进行数据库备份
【9月更文挑战第13天】以下是使用MySQL Workbench进行数据库备份的步骤:启动软件后,通过“Database”菜单中的“管理连接”选项配置并选择要备份的数据库。随后,选择“数据导出”,确认导出的数据库及格式(推荐SQL格式),设置存储路径,点击“开始导出”。完成后,可在指定路径找到备份文件,建议定期备份并存储于安全位置。
158 11
|
2月前
|
弹性计算 关系型数据库 数据库
手把手带你从自建 MySQL 迁移到云数据库,一步就能脱胎换骨
阿里云瑶池数据库来开课啦!自建数据库迁移至云数据库 RDS原来只要一步操作就能搞定!点击阅读原文完成实验就可获得一本日历哦~
|
2月前
|
关系型数据库 MySQL 数据库
RDS MySQL灾备服务协同解决方案构建问题之数据库备份数据的云上云下迁移如何解决
RDS MySQL灾备服务协同解决方案构建问题之数据库备份数据的云上云下迁移如何解决
|
14天前
|
存储 SQL 关系型数据库
MySQL的安装&数据库的简单操作
本文介绍了数据库的基本概念及MySQL的安装配置。首先解释了数据库、数据库管理系统和SQL的概念,接着详细描述了MySQL的安装步骤及其全局配置文件my.ini的调整方法。文章还介绍了如何启动MySQL服务,包括配置环境变量和使用命令行的方法。最后,详细说明了数据库的各种操作,如创建、选择和删除数据库的SQL语句,并提供了实际操作示例。
57 13
MySQL的安装&数据库的简单操作
|
20天前
|
存储 SQL 关系型数据库
一篇文章搞懂MySQL的分库分表,从拆分场景、目标评估、拆分方案、不停机迁移、一致性补偿等方面详细阐述MySQL数据库的分库分表方案
MySQL如何进行分库分表、数据迁移?从相关概念、使用场景、拆分方式、分表字段选择、数据一致性校验等角度阐述MySQL数据库的分库分表方案。
一篇文章搞懂MySQL的分库分表,从拆分场景、目标评估、拆分方案、不停机迁移、一致性补偿等方面详细阐述MySQL数据库的分库分表方案
|
1天前
|
关系型数据库 Unix MySQL
MySQL是一种关系型数据库管理系统
MySQL是一种关系型数据库管理系统
8 2
下一篇
无影云桌面