All Products
Search
Document Center

Elastic Compute Service:Modify the private IP address of an instance

Last Updated:May 14, 2024

When you use an Elastic Compute Service (ECS) instance, you may need to modify the private IP address of the instance to prevent IP conflict, extend networks, or manage networks. You can directly modify the private IP address of an instance that resides in a virtual private cloud (VPC). Alternatively, you can change the vSwitch to which an instance is connected to modify the private IP address of the instance. This topic describes how to modify the private IP address of an instance in the ECS console.

Prerequisites

  • No secondary private IP address is associated with the elastic network interface (ENI) of the instance whose private IP address you want to modify.

  • The instance is in the Stopped state. For more information, see Stop an instance.

Procedure

  1. Log on to the ECS console.

  2. In the left-side navigation pane, choose Instances & Images > Instances.

  3. In the top navigation bar, select the region and resource group to which the resource belongs. 地域

  4. Find the instance whose private IP address you want to modify, and choose icon1 > Network and Security Group > Modify Private IP Address in the Actions column.

  5. In the Modify Private IP Address dialog box, configure parameters for the new private IP address and click Confirm.

    • If you want to change the vSwitch to which the instance is connected, make sure that the new vSwitch and the instance reside in the same zone.

    • If you do not want to change the vSwitch to which the instance is connected, you only need to enter a new private IP address in the Private IP Address field.

      Note

      If you do not enter a new private IP address, the system automatically assigns a new private IP address.

  6. On the Instance page, find the instance, and choose icon1 > Instance Status > Start in the Actions column.

    Note

    Start the instance to allow the new private IP address to take effect.

References