All Products
Search
Document Center

Elastic Compute Service:Unassign secondary private IP addresses

Last Updated:May 15, 2024

When an elastic network interface (ENI) no longer requires secondary private IP addresses, you can unassign the secondary private IP addresses from the ENI. This topic describes how to unassign secondary private IP addresses from an ENI in the Elastic Compute Service (ECS) console.

Prerequisites

Before you unassign secondary private IP addresses from an ENI, make sure that the following prerequisites are met:

  • One or more secondary private IP addresses are assigned to the ENI.

  • The ENI is in the to be bound (Available) or Bound (InUse) state.

  • When you unassign secondary private IP addresses from a primary ENI, the ECS instance to which the primary ENI is bound is in the Running (Running) or Stopped (Stopped) state.

Procedure

  1. Log on to the ECS console.

  2. In the left-side navigation pane, choose Network & Security > Elastic Network Interfaces.

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

  4. On the Elastic Network Interfaces page, find the ENI from which you want to unassign secondary private IP addresses. In the Operation column, click Manage ENI IP Addresses.

  5. In the Manage ENI IP Addresses dialog box, find the secondary private IP addresses that you want to unassign in the Secondary Private IPv4 Address section and click the image.png icon on the right side of the IP addresses.

  6. Click Confirm.

    Refresh the ENI list. If the IP Address column of the ENI no longer displays the secondary private IP addresses that you unassigned, the secondary private IP addresses are unassigned from the ENI.

References

  • If you want to unassign one or more secondary private IP addresses from an ENI, call the UnassignPrivateIpAddresses operation.

  • After you unassign secondary private IP addresses, you may need to reconfigure security group rules for the associated ECS instance. For more information, see Modify a security group rule.

  • You can configure event notifications in EventBridge or CloudMonitor to receive notifications about IP address events. After you unassign private IP addresses from an ENI, you are notified of the results by emails or DingTalk chatbots. You can obtain information about the unassignment events, such as the unassigned secondary private IP addresses and the associated ENI ID, and specify the operations that you want to be automatically performed in response to the notifications. For more information, see Configure event notifications, ECS events, and the Notifications for private IPv4 address reclamation events section in the "IP address event notifications" topic.