This topic describes how to switch to a new VPC and VSwitch for an RDS MySQL instance.
- For local SSD instances, you can modify Virtual Private Cloud and vSwitch directly.
- For standard SSD or ESSD instances, you can only modify the vSwitch, not the Virtual Private Cloud.
- The RDS instance is disconnected for about 30 seconds during the switchover. Make sure that your application can automatically reconnect to the RDS instance.
- The virtual IP address of the RDS instance changes after the switchover. We recommend that you use an endpoint of the RDS instance to establish a connection.
- The DRDS is unavailable for a short period of time due to the change to the virtual IP address during the switchover. You must update and view the connection information of the RDS instance in the console immediately after the switchover is complete.
- The DMS and DTS is unavailable for a short period of time due to the change to the virtual IP address during the switchover, and automatically returns to normal after the switchover is complete.
- You must clear the cache on your database client properly. If you do not do so, data can be read but cannot be written into the RDS instance.
- Log on to the ApsaraDB for RDS console.
- In the left-side navigation pane, click Instances. In the top navigation bar, select the region where the target RDS instance resides.
- Find the target instance and click the instance ID.
- In the left-side navigation pane, click Database Connection.
- In the upper-right corner, click Switch VSwitch.
- Select a VPC and a VSwitch, then click OK.Note To create a VPC or VSwitch, click go to the VPC console.
- In the displayed dialog box, click the button for confirming the switchover.
How do I change the VPC of an RDS instance if that instance does not allow me to switch to a new VPC and VSwitch?
- If your RDS instance supports direct network type changes:
Note For more information, see Change the network type of an ApsaraDB RDS for MySQL instance.
- Switch the network type from VPC to Classic Network.
- Switch the network type from classic network to the target VPC.
- If your RDS instance does not support direct network type changes:
Purchase a new RDS instance with the destination VPC selected, and then migrate data to the new RDS instance. For more information, see Migrate data between ApsaraDB for RDS instances.
For instances that do not support switching Virtual Private Cloud and vswitches directly, see Change the VPC for an ApsaraDB for RDS instance.