在最短的停机时间内迁移到 Azure Database for PostgreSQL(单一服务器)Minimal-downtime migration to Azure Database for PostgreSQL - Single Server

可以使用新引入的适用于 Azure 数据库迁移服务 (DMS) 的连续同步功能,在尽量减少停机时间的情况下将 PostgreSQL 迁移到 Azure Database for PostgreSQL。You can perform PostgreSQL migrations to Azure Database for PostgreSQL with minimal downtime by using the newly introduced continuous sync capability for the Azure Database Migration Service (DMS). 此功能限制应用程序引发的停机时间。This functionality limits the amount of downtime that is incurred by the application.

概述Overview

Azure DMS 将本地内容初始加载到 Azure Database for PostgreSQL,然后在应用程序仍在运行时不断地将任何新事务同步到 Azure。Azure DMS performs an initial load of your on-premises to Azure Database for PostgreSQL, and then continuously syncs any new transactions to Azure while the application remains running. 当数据在目标 Azure 端赶上进度以后,即可停止应用程序一段时间(最短停机时间),等待目标端的最后一批数据(从停止应用程序开始计算,直至应用程序事实上不可用,以便获取新的流量)赶上,然后更新连接字符串,使之指向 Azure。After the data catches up on the target Azure side, you stop the application for a brief moment (minimum downtime), wait for the last batch of data (from the time you stop the application until the application is effectively unavailable to take any new traffic) to catch up in the target, and then update your connection string to point to Azure. 完成以后,应用程序将留存在 Azure 中!When you are finished, your application will be live on Azure!

使用 Azure 数据库迁移服务进行连续同步

后续步骤Next steps