Help Center/ Virtual Private Cloud/ User Guide/ VPC and Subnet/ Subnet/ Managing Subnet CIDR Reservations
Updated on 2025-08-01 GMT+08:00

Managing Subnet CIDR Reservations

Scenarios

IP addresses in a subnet CIDR reservation will not be assigned to instances in the subnet. You can perform the following operations on CIDR reservations:

Precautions

A CIDR reservation must be a subset of its subnet CIDR block and cannot contain the start IP address, end IP address, and assigned IP addresses in the subnet CIDR block. For example, if the IPv4 subnet CIDR block is 192.168.1.0/24, the following IP addresses cannot be included in a CIDR reservation:
  • Start IP address: 192.168.1.0
  • End broadcast address: 192.168.1.255
  • Assigned IP addresses
    • Subnet gateway address: 192.168.1.1
    • DHCP address: 192.168.1.254
    • System interface address: 192.168.1.253
    • IP addresses used by instances in the subnet

    You can view the IP addresses that are already in use in a subnet by referring to Viewing IP Addresses in a Subnet.

Creating a Subnet CIDR Reservation

  1. Go to the subnet list page.
  2. Locate the target subnet and click its name.

    The subnet details page is displayed.

  3. Click the CIDR Reservations tab. In the upper left corner of the CIDR reservation list, click Add CIDR Reservation.
  4. Configure the CIDR reservation parameters as needed.
    For details, see Table 1.
    Table 1 Parameters for configuring a CIDR reservation

    Parameter

    Description

    Example Value

    Name

    Mandatory

    Enter a name for the CIDR reservation. The name:

    • Can contain 1 to 64 characters.
    • Can contain letters, digits, underscores (_), hyphens (-), and periods (.).

    CIDR reservations can share the same name, but each one has a unique ID assigned by the system.

    subnet-reserved-cidr-01

    IP Address Version

    Mandatory

    Set the IP address version supported by the CIDR reservation. There are two options:
    • IPv4
    • IPv6: If you select this option, the subnet must have IPv6 enabled.
      To enable IPv6:
      • In the subnet list, locate the target subnet and click Enable IPv6 in the IPv6 CIDR Block column.
      • In the Summary tab of the target subnet, click Enable for IPv6 CIDR Block.

    IPv4

    Creation Method

    Mandatory

    Define how you want to add a CIDR reservation. There are two options:

    • Specify CIDR block: You need to enter a CIDR block.

      A CIDR reservation must be a subset of its subnet CIDR block and cannot contain the start IP address, end IP address, and assigned IP addresses in the subnet CIDR block. The following are examples:

      • IPv4 CIDR block: If the subnet CIDR block is 192.168.1.0/24, you can set the CIDR reservation to 192.168.1.128/26.
      • IPv6 CIDR block: If the subnet CIDR block is 2407:c080:1200:2515::/64, you can set the CIDR reservation to 2407:c080:1200:2515:6a8c::/80.
    • Specify mask length: You need to enter a mask length. The length must be an integer.

      The minimum mask length is the subnet mask length plus 2. The system will assign a CIDR reservation based on the mask length you have specified. The following are examples:

      • IPv4 CIDR block mask length: If the subnet CIDR block is 192.168.1.0/24 and the subnet mask is 24, the CIDR reservation mask ranges from 26 to 32. If you set the mask length to 26, the system automatically assigns a CIDR reservation of 192.168.1.128/26.
      • IPv6 CIDR block mask length: If the subnet CIDR block is 2407:c080:1200:2515::/64 and the subnet mask is 64, the CIDR reservation mask ranges from 66 to 128. If you set the mask length to 80, the system automatically assigns a CIDR reservation of 2407:c080:1200:2515:7a3d::/80.
    • Specify CIDR block: 192.168.1.128/26
    • Specify mask length: 26

    Description

    Optional

    Enter a description about the CIDR reservation in the text box as required.

    The description can contain a maximum of 255 characters and cannot contain angle brackets (< or >).

    -

  5. Click OK.

    Return to the CIDR reservation list and view the CIDR reservations in the current subnet.

Modifying the Name and Description of a CIDR Reservation

  1. Go to the subnet list page.
  2. Locate the target subnet and click its name.

    The subnet details page is displayed.

  3. Click the CIDR Reservations tab. In the CIDR reservation list, locate the target CIDR reservation and click on the right of its name or description and enter a different value.
    Table 2 Parameter descriptions

    Parameter

    Description

    Example Value

    Name

    Name of the CIDR reservation. The name:

    • Can contain 1 to 64 characters.
    • Can contain letters, digits, underscores (_), hyphens (-), and periods (.).

    CIDR reservations can share the same name, but each one has a unique ID assigned by the system.

    subnet-reserved-cidr-02

    Description

    Description of the CIDR reservation.

    The description can contain a maximum of 255 characters and cannot contain angle brackets (< or >).

    -

  4. Click OK.

Deleting a Subnet CIDR Reservation

  1. Go to the subnet list page.
  2. Locate the target subnet and click its name.

    The subnet details page is displayed.

  3. Click the CIDR Reservations tab. In the CIDR reservation list, locate the target CIDR reservation and click Delete in the Operation column.

    A confirmation dialog box is displayed.

  4. Confirm the information and click OK.

    After a CIDR reservation is deleted, the IP addresses in the CIDR block will be assigned to instances in the subnet.