Help Center/ Auto Scaling/ Best Practices/ Automatically Binding EIPs During Capacity Expansion and Releasing EIPs During Reduction
Updated on 2025-07-16 GMT+08:00

Automatically Binding EIPs During Capacity Expansion and Releasing EIPs During Reduction

Background

  • If no EIPs are assigned to the ECSs added to an AS group, the ECSs cannot provide public access. The system can automatically assign EIPs to the new ECSs during capacity expansion to keep them accessible.
  • If you want to release ECS resources (for example, during off-peak hours) or no longer need public network access, the system can automatically release the EIPs (if any) during capacity reduction to optimize resource usage and reduce costs.

An EIP is a public IP address that can be purchased and held independently. It can be bound to or unbound from an ECS. For details about EIP, see What Are EIPs?

Preparations

You have created an AS group and enabled it. For details, see Creating an AS Group.

Automatically Binding EIPs to ECSs During Capacity Expansion

  1. Modify the AS configuration of the AS group.
    1. Log in to the Huawei Cloud console.
    2. On the console, choose Compute > Auto Scaling > Instance Scaling.
    3. On the Instance Scaling page, locate the AS group and choose More > Modify AS Configuration in the Operation column. Configure parameters listed in Table 1.

      This section uses the following parameters as an example. Retain the default values for the parameters that are not listed. For details, see Using a New Specifications Template to Create an AS Configuration.

      Table 1 Parameters for configuring the AS configuration

      Parameter

      Example Value

      Description

      Name

      as-config-test

      Enter a name for the AS configuration as instructed.

      Billing Mode

      Pay-per-use

      Pay-per-use is a post-paid charging mode, so the total expenditure depends directly on ECS usage frequency and duration.

      You can create or delete your ECSs at any time.

      Flavor

      s3.small.1

      You can select a maximum of 10 flavors.

      You are advised to select several similar flavors based on the vCPU, memory, bandwidth, or the maximum number of packets that an ECS can transmit and receive per second.

      Image

      test

      The image is used to deploy ECSs.

      You are advised to select the custom image where you have deployed your applications.

      System Disk

      General Purpose SSD, 100 GiB

      Select a system disk for ECSs based on service requirements.

      Security Group

      sg-bp18kz60mefsicfg****

      Select the security group you have created. For details about how to create a security group, see Creating a Security Group.

      EIP

      Automatically assign

      The system automatically assigns an EIP with a dedicated bandwidth to each ECS. The bandwidth is configurable.

    4. Click OK.
  2. Set a capacity expansion policy to trigger a capacity expansion action. For details, see Creating an AS Policy.
  3. Check whether the new ECSs have EIPs bound.

    In the instance list of the AS group, click the ID of each created ECS. On the ECS details page, check whether the ECS has an EIP bound.

Releasing EIPs from ECSs During Capacity Reduction

  1. Modify the AS group.
    1. Log in to the Huawei Cloud management console.
    2. On the console, choose Compute > Auto Scaling > Instance Scaling.
    3. On the Instance Scaling page, locate the AS group and choose More > Modify AS Group in the Operation column. Configure parameters listed in Table 2.

      This section uses the following parameters as an example. Retain the default values for the parameters that are not listed. For details, see Creating an AS Group.

      Table 2 Parameters for configuring the AS group

      Parameter

      Example Value

      Description

      EIP

      Release

      If you select Release, the system releases the EIP from the ECS when an ECS is removed from the AS group. Otherwise, the system reserves the EIP.

    4. Click OK.
  2. Set a capacity reduction policy to trigger a capacity reduction action. For details, see Creating an AS Policy.
  3. Check whether the EIPs of the ECSs removed from the AS group have been released.

    You can go to the EIP list to check if they are displayed. If the EIPs do not exist, they have been released.