|
| 1 | +--- |
| 2 | +title: "In-place automigration from Azure Database for MySQL – Single Server to Flexible Server" |
| 3 | +description: This tutorial describes how to configure notifications, review migration details and FAQs for an Azure Database for MySQL Single Server instance schedule for in-place automigration to Flexible Server. |
| 4 | +author: adig |
| 5 | +ms.author: adig |
| 6 | +ms.date: 07/10/2023 |
| 7 | +ms.service: mysql |
| 8 | +ms.subservice: flexible-server |
| 9 | +ms.topic: quickstart |
| 10 | +ms.custom: |
| 11 | + - mvc |
| 12 | + - devx-track-azurecli |
| 13 | + - mode-api |
| 14 | +--- |
| 15 | +# In-place automigration from Azure Database for MySQL – Single Server to Flexible Server |
| 16 | + |
| 17 | +[!INCLUDE[applies-to-mysql-single-server](../includes/applies-to-mysql-single-server.md)] |
| 18 | + |
| 19 | +In-place automigration from Azure Database for MySQL – Single Server to Flexible Server is a service-initiated in-place migration during planned maintenance window for Single Server database workloads with Basic or General Purpose SKU, data storage used < 10 GiB and no complex features enabled. The eligible servers are identified by the service and are sent an advance notification detailing steps to review migration details. |
| 20 | + |
| 21 | +The in-place migration provides a highly resilient and self-healing offline migration experience during a planned maintenance window, with less than 5 mins of downtime. It uses backup and restore technology for faster migration time. This migration removes the overhead to manually migrate your server and ensure you can take advantage of the benefits of Flexible Server, including better price & performance, granular control over database configuration, and custom maintenance windows. Following described are the key phases of the migration: |
| 22 | + |
| 23 | +* Target Flexible Server is deployed, inheriting all feature set and properties (including server parameters and firewall rules) from source Single Server. Source Single Server is set to read-only and backup from source Single Server is copied to the target Flexible Server. |
| 24 | +* DNS switch and cutover are performed successfully within the planned maintenance window with minimal downtime, allowing maintenance of the same connection string post-migration. Client applications seamlessly connect to the target flexible server without any user driven manual updates. In addition to both connection string formats (Single and Flexible Server) being supported on migrated Flexible Server, both username formats – username@server_name and username are also supported on the migrated Flexible Server. |
| 25 | +* The migrated Flexible Server is online and can now be managed via Azure portal/CLI. Stopped Single Server is deleted post days set as it's Backup Retention Period. |
| 26 | + |
| 27 | +> [!NOTE] |
| 28 | +> In-place migration is only for Single Server database workloads with Basic or GP SKU, data storage used < 10 GiB and no complex features enabled. All other Single Server workloads are recommended to use user-initiated migration tooling offered by Azure - Azure DMS, Azure MySQL Import to migrate. |
| 29 | +
|
| 30 | +## Configure migration alerts and review migration schedule |
| 31 | + |
| 32 | +Servers eligible for in-place automigration are sent an advance notification by the service. |
| 33 | + |
| 34 | +Following described are the ways to check and configure automigration notifications: |
| 35 | + |
| 36 | +* Subscription owners for Single Servers scheduled for automigration receive an email notification. |
| 37 | +* Configure service health alerts to receive in-place migration schedule and progress notifications via email/SMS by following steps [here](../single-server/concepts-planned-maintenance-notification.md#to-receive-planned-maintenance-notification). |
| 38 | +* Check the in-place migration notification on the Azure portal by following steps [here](../single-server/concepts-planned-maintenance-notification.md#check-planned-maintenance-notification-from-azure-portal). |
| 39 | + |
| 40 | +Following described are the ways to review your migration schedule once you have received the in-place automigration notification: |
| 41 | + |
| 42 | +> [!NOTE] |
| 43 | +> The migration schedule will be locked 7 days prior to the scheduled migration window after which you’ll be unable to reschedule. |
| 44 | +
|
| 45 | +* The Single Server overview page for your instance displays a portal banner with information about your migration schedule. |
| 46 | +* For Single Servers scheduled for automigration, a new Migration blade is lighted on the portal. You can review the migration schedule by navigating to the Migration blade of your Single Server instance. |
| 47 | +* If you wish to defer the migration, you can defer by a month at a time by navigating to the Migration blade of your single server instance on the Azure portal and rescheduling the migration by selecting another migration window within a month. |
| 48 | +* If your Single Server has General Purpose SKU, you have the other option to enable High Availability when reviewing the migration schedule. As High Availability can only be enabled during create time for a MySQL Flexible Server, it's highly recommended that you enable this feature when reviewing the migration schedule. |
| 49 | + |
| 50 | +## How is the target MySQL Flexible Server auto-provisioned? |
| 51 | + |
| 52 | +* The compute tier and SKU for the target flexible server is provisioned based on the source single server’s pricing tier and VCores based on the detail in the following table. |
| 53 | + |
| 54 | + | Single Server Pricing Tier | Single Server VCores | Flexible Server Tier | Flexible Server SKU Name | |
| 55 | + | ------------- | ------------- |:-------------:|:-------------:| |
| 56 | + | Basic | 1 | Burstable | Standard_B1s | |
| 57 | + | Basic | 2 | Burstable | Standard_B2s | |
| 58 | + | General Purpose | 4 | GeneralPurpose | Standard_D4ds_v4 | |
| 59 | + | General Purpose | 8 | GeneralPurpose | Standard_D8ds_v4 | |
| 60 | + | General Purpose | 16 | GeneralPurpose | Standard_D16ds_v4 | |
| 61 | + | General Purpose | 32 | GeneralPurpose | Standard_D32ds_v4 | |
| 62 | + | General Purpose | 64 | GeneralPurpose | Standard_D64ds_v4 | |
| 63 | + | Memory Optimized | 4 | MemoryOptimized | Standard_E4ds_v4 | |
| 64 | + | Memory Optimized | 8 | MemoryOptimized | Standard_E8ds_v4 | |
| 65 | + | Memory Optimized | 16 | MemoryOptimized | Standard_E16ds_v4 | |
| 66 | + | Memory Optimized | 32 | MemoryOptimized | Standard_E32ds_v4 | |
| 67 | + |
| 68 | +* The MySQL version, region, *storage size, subscription and resource group for the target Flexible Server is same as that of the source Single Server. |
| 69 | +*For Single Servers with less than 20 GiB storage, the storage size is set to 20 GiB as that is the minimum storage limit on Azure Database for MySQL - Flexible Server. |
| 70 | +* Both username formats – username@server_name (Single Server) and username (Flexible Server) are supported on the migrated Flexible Server. |
| 71 | +* Both connection string formats – Single Server and Flexible Server are supported on the migrated Flexible Server. |
| 72 | + |
| 73 | +## Post-migration steps |
| 74 | + |
| 75 | +Copy the following properties from the source Single Server to target Flexible Server post in-place migration operation is completed successfully: |
| 76 | + |
| 77 | +* Monitoring page settings (Alerts, Metrics, and Diagnostic settings) |
| 78 | +* Any Terraform/CLI scripts you host to manage your Single Server instance should be updated with Flexible Server references. |
| 79 | + |
| 80 | +## Frequently Asked Questions (FAQs) |
| 81 | + |
| 82 | +**Q. Why am I being auto-migrated?** |
| 83 | + |
| 84 | +**A.** Your Azure Database for MySQL - Single Server instance is eligible for in-place migration to our flagship offering Azure Database for MySQL - Flexible Server. This in-place migration will remove the overhead to manually migrate your server and ensure you can take advantage of the benefits of Flexible Server, including better price & performance, granular control over database configuration, and custom maintenance windows. |
| 85 | + |
| 86 | +**Q. How does the automigration take place? What all does it migrate?** |
| 87 | + |
| 88 | +**A.** The Flexible Server is provisioned to match the same VCores and storage as that of your Single Server. Next the source Single Server is put to stopped state, data file snapshot is taken and copied to target Flexible Server. The DNS switch is performed to route all existing connections to target and the target Flexible Server is brought online. The automigration migrates the entire server’s data files (including schema, data, logins) in addition to server parameters (all modified server parameters on source are copied to target, unmodified server parameters take up the default value defined by Flexible Server) and firewall rules. This is an offline migration where you see downtime of up-to 5 minutes or less. |
| 89 | + |
| 90 | +**Q. How can I set up or view in-place migration alerts?** |
| 91 | + |
| 92 | +**A.** |
| 93 | + |
| 94 | +* Configure service health alerts to receive in-place migration schedule and progress notifications via email/SMS by following steps [here](../single-server/concepts-planned-maintenance-notification.md#to-receive-planned-maintenance-notification). |
| 95 | +* Check the in-place migration notification on the Azure portal by following steps [here](../single-server/concepts-planned-maintenance-notification.md#check-planned-maintenance-notification-from-azure-portal). |
| 96 | + |
| 97 | +**Q. How can I defer the scheduled migration?** |
| 98 | + |
| 99 | +**A.** You can review the migration schedule by navigating to the Migration blade of your Single Server instance. If you wish to defer the migration, you can defer by a month at the most by navigating to the Migration blade of your single server instance on the Azure portal and re-scheduling the migration by selecting another migration window within a month. Note that the migration details will be locked 7 days prior to the scheduled migration window after which you're unable to reschedule. This in-place migration can be deferred monthly until 16 September 2024. |
| 100 | + |
| 101 | +**Q. What are some post-migration activities I need to perform?** |
| 102 | + |
| 103 | +**A.** |
| 104 | + |
| 105 | +* Monitoring page settings (Alerts, Metrics, and Diagnostic settings) |
| 106 | +* Any Terraform/CLI scripts you host to manage your Single Server instance should be updated with Flexible Server references. |
| 107 | + |
| 108 | +**Q. What username and connection string would be supported for the migrated Flexible Server? ** |
| 109 | + |
| 110 | +**A.** Both username formats - username@server_name (Single Server format) and username (Flexible Server format) will be supported for the migrated Flexible Server, and hence you aren't required to update them to maintain your application continuity post migration. Additionally, both connection string formats (Single and Flexible server format) will also be supported for the migrated Flexible Server. |
| 111 | + |
| 112 | +**Q. How to enable HA (High Availability) for my auto-migrated server??** |
| 113 | + |
| 114 | +**A.** By default, automigration sets up migration to a non-HA instance. As HA can only be enabled at server-create time, you should enable HA before the scheduled automigration using the automigration schedule edit option on portal. HA can only be enabled for General purpose\Memory Optimized SKUs on target Flexible Server, as Basic to Burstable SKU migration doesn’t support HA configuration. |
| 115 | + |
| 116 | +**Q. I see a pricing difference on my potential move from MySQL Basic Single Server to MySQL Flexible Server??** |
| 117 | + |
| 118 | +**A.** Few servers may see a small price increase after migration (estimated costs can be seen by clicking the automigration schedule edit option on the portal), as the minimum storage limit on both offerings is different (5 GiB on Single Server; 20 GiB on Flexible Server) and storage cost (0.1$ on Single Server; 0.115$ on Flexible Server) for Flexible Server is slightly higher than Single Server. For impacted servers, this price increase in Flexible Server provides better throughput and performance compared to Single Server |
| 119 | + |
| 120 | +## Next steps |
| 121 | + |
| 122 | +* [Manage an Azure Database for MySQL - Flexible Server using the Azure portal](../flexible-server/how-to-manage-server-portal.md) |
0 commit comments