All Products
Search
Document Center

AnalyticDB:Change the VPC and vSwitch

Last Updated:Jun 25, 2026

If your AnalyticDB for MySQL cluster and an ECS instance are in different VPCs, you can change the VPC and vSwitch of the cluster to enable communication over the AnalyticDB for MySQL.

Precautions

  • Changing the VPC and vSwitch is an asynchronous operation. During the change, the cluster may experience brief connection interruptions and read/write failures. We recommend that you perform this operation during off-peak hours and ensure your application can reconnect automatically.

  • Changing the VPC and vSwitch changes the virtual IP address (VIP). To ensure a stable connection, use the cluster's VPC endpoint (for example, am-bp13er819d288****90650.ads.aliyuncs.com) in your application. This endpoint remains unchanged.

    After the change, your application may fail to connect to the cluster for several minutes due to local DNS cache updates.

  • Changing the VPC and vSwitch does not automatically update the IP address whitelist. If the CIDR block of the network changes, the IP address whitelist may become invalid. You must reconfigure the whitelist.

  • If you have enabled the elastic network interface (ENI) feature, the elastic network interface (ENI) does not automatically switch to the new VPC and vSwitch. To switch the ENI, you must first disable and then re-enable the feature.

  • For Enterprise Edition, Basic Edition, Data Lakehouse Edition, and Data Warehouse Edition (Elastic Mode) clusters, you can delete the original VPC and vSwitch after the change. For Data Warehouse Edition (Reserved Mode) clusters, you cannot delete the original VPC and vSwitch because some underlying applications remain deployed in the original VPC and vSwitch.

  • For Enterprise Edition, Basic Edition, and Data Lakehouse Edition clusters, after you change the VPC and vSwitch, you must manually update the VPC ID and vSwitch ID in Notebook resources to match the new network. Otherwise, job submissions will fail.

Procedure

  1. Log on to the AnalyticDB for MySQL console. In the upper-left corner, select the region where your cluster is located. In the left-side navigation pane, click Clusters, and then click the ID of your target cluster.

  2. In the Network Information section, click Change VPC and vSwitch next to the VPC ID.

  3. In the Change VPC and vSwitch dialog box, select a VPC and a vSwitch.

    Note

    If no VPCs or vSwitches are available in the drop-down lists, no other VPCs or vSwitches exist in the current region. You must first create a new VPC and vSwitch. For more information, see Create and manage a VPC.

  4. Click OK.

    Note

    During the change, the cluster status changes to Modifying Network Address. The change is complete when the cluster status returns to Running.