Deletes a reserved CIDR block of a vSwitch.
Operation description
Description
-
Before you call this operation, make sure that the IP address allocated to an elastic network interface (ENI) from the reserved CIDR block is deleted. If the IP address of the ENI is not deleted, call UnassignPrivateIpAddresses or UnassignIpv6Addresses to delete the IPv4 or IPv6 address.
-
DeleteVSwitchCidrReservation is an asynchronous operation. After a request is sent, the system returns a request ID and runs the task in the background. You can call ListVSwitchCidrReservations to query the status of the task:
- If the reserved CIDR block is in the Releasing state, it is being released.
- If the reserved CIDR block is in the Released state, it is released.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- For mandatory resource types, indicate with a prefix of * .
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
vpc:DeleteVSwitchCidrReservation | delete | *VSwitchCidrReservation acs:vpc:{#regionId}:{#accountId}:vswitchcidrreservation/{#VSwitchCidrReservationId} |
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
VSwitchCidrReservationId | string | Yes | The ID of the reserved CIDR block. | vcr-bp1m12saqteraw3rp**** |
RegionId | string | Yes | The ID of the region where the vSwitch is deployed. You can call the DescribeRegions operation to query the most recent region list. | cn-hangzhou |
DryRun | boolean | No | Specifies whether to perform a dry run. Valid values: true: performs a dry run. The system checks the required parameters, request format, and limits. If the request fails the dry run, an error message is returned. If the request passes the dry run, the false (default): performs a dry run and sends the request. If the request passes the dry run, a 2xx HTTP status code is returned and the operation is performed. | false |
ClientToken | string | No | The client token that is used to ensure the idempotence of the request. You can use the client to generate the token, but you must make sure that the token is unique among different requests. The token can contain only ASCII characters. Note
If you do not specify this parameter, the system automatically uses the request ID as the client token. The request ID may be different for each request.
| 123e4567-e89b-12d3-a456-426655440000 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "54B48E3D-DF70-471B-AA93-08E683A1B45"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | DependencyViolation.IpPrefix | DependencyViolation.IpPrefix | The error message returned because a prefix list is assigned to the resource. Delete the prefix list and try again. |
400 | IncorrectStatus.CidrReservation | The status of the CIDR reservation is incorrect. | The status of the reserved CIDR block does not support this operation. Try again later. |
400 | ResourceNotFound.CidrReservation | reserve segment not exist. | The network segment does not exist. |
404 | ResourceNotFound.CidrReservation | ResourceNotFound.CidrReservation | The error message returned because VSwitchCidrReservation is set to an invalid value. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-07-24 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2024-06-24 | The Error code has changed | View Change Details |
2024-04-11 | The Error code has changed | View Change Details |