Modifies the attributes, such as the name, description, and security group of an elastic network interface (ENI).
Debugging
Authorization information
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID of the ENI. You can call the DescribeRegions operation to query the most recent region list. | cn-hangzhou |
NetworkInterfaceName | string | No | The name of the ENI. The name must be 2 to 128 characters in length. The name must start with a letter and cannot start with http:// or https://. The name can contain letters, digits, colons (:), underscores (_), and hyphens (-). This parameter is empty by default. | eniTestName |
NetworkInterfaceId | string | Yes | The ID of the ENI. | eni-bp67acfmxazb4p**** |
QueueNumber | integer | No | The number of queues supported by the ENI. Valid values: 1 to 2048.
| 8 |
Description | string | No | The description of the ENI. The description must be 2 to 255 characters in length and cannot start with http:// or https://. This parameter is left empty by default. | testDescription |
SecurityGroupId | array | No | The IDs of the security groups to which to add the secondary ENI. The secondary ENI is added to the specified security groups and are removed from its original security groups.
| |
string | No | The ID of security group N.
| sg-bp67acfmxazb4p**** | |
DeleteOnRelease | boolean | No | Specifies whether to release the ENI when the associated instance is released. Valid values:
| true |
RxQueueSize | integer | No | The receive (Rx) queue depth of the ENI. Take note of the following items:
| 8192 |
TxQueueSize | integer | No | The Tx queue depth of the ENI. Take note of the following items:
| 8192 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3****"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | InvalidOperation.NotSupportModifyQueueNumber | %s | - |
400 | MissingParameter | %s | A parameter is not specified. |
400 | UnsupportedParameter | %s | The parameter is not supported. |
400 | InvalidParameter | %s | The specified parameter is invalid. |
400 | InvalidInstanceID.Malformed | %s | The specified InstanceId parameter is invalid. |
400 | InvalidOperation.InvalidEcsState | %s | - |
400 | InvalidOperation.InvalidEniState | %s | - |
400 | InvalidOperation.DetachPrimaryEniNotAllowed | %s | - |
400 | InvalidParams.EniId | %s | The specified EniId parameter is invalid. |
400 | Forbidden.RegionId | %s | The service is unavailable in the current region. |
400 | JoinedGroupLimitExceed | %s | The maximum number of security groups to which the specified resource can be added has been reached. For more information, see the return value of the %s placeholder in the error message. |
400 | InvalidEniQueueSize.RegionOrUserNotSupported | The specified parameter RxQueueSize or TxQueueSize is not supported in this region, or this account is not in the whitelist of using eni QueueSize. | You are not authorized to specify the length of NIC queues or cannot specify the length of NIC queues in the current region. |
400 | InvalidParameter.EniQueueSize | The specified parameter TxQueueSize and RxQueueSize are not equal or exceed limit. | The specified parameter TxQueueSize and RxQueueSize are not equal or exceed limit. |
403 | InvalidUserType.NotSupported | %s | Your account does not support this operation. |
403 | Abs.InvalidAccount.NotFound | %s | Your Alibaba Cloud account does not exist or your AccessKey pair has expired. |
403 | Forbidden.NotSupportRAM | %s | RAM users are not authorized to perform this operation. |
403 | Forbidden.SubUser | %s | You are not authorized to manage this resource. Contact the owner of the Alibaba Cloud account for authorization. |
403 | MaxEniCountExceeded | %s | The maximum number of ENIs that can be managed has been reached. |
403 | EniPerInstanceLimitExceeded | %s | The maximum number of ENIs that can be attached to the specified instance has been reached. |
403 | InvalidOperation.AvailabilityZoneMismatch | %s | The operation is invalid. |
403 | InvalidOperation.VpcMismatch | %s | The operation is invalid. Check whether the VPC in the operation corresponds to other parameters. |
403 | SecurityGroupInstanceLimitExceed | %s | - |
403 | InvalidSecurityGroupId.NotVpc | %s | The specified SecurityGroupId parameter is invalid and the network type of the security group is not VPC. |
403 | InvalidOperation.InvalidEniType | %s | - |
403 | InvalidOperation.EniServiceManaged | %s | The operation is invalid. |
403 | InvalidOperation.MultiGroupType | The specified instance can't join different types of security group. | - |
403 | InvalidOperation.EniCountExceeded | The maximum number of eni in a enterprise level security group is exceeded. | - |
403 | InvalidParams.NetworkInterfaceName | %s | - |
403 | InvalidOperation.ModifyPrimaryEniQueueNumber | Primary NetworkInterface is not allowed to modify queue number. | - |
403 | InvalidOperation.InvalidEniState | Available status or ECS instance attached is Stopped is allowed to modify network interface queue number. | - |
403 | InvalidOperation.ResourceManagedByCloudProduct | %s | You cannot modify security groups managed by cloud services. |
403 | InvalidParameter.InvalidEniQueueNumber | %s | - |
403 | InvalidOperation.MaxEniQueueNumberExceeded | %s | - |
403 | InvalidOperation.ExceedInstanceTypeQueueNumber | %s | The maximum number of queues for all ENIs on an instance has been exceeded. For more information, see the return value of the %s placeholder in the error message. |
403 | AclLimitExceed | %s | The number of ACL rules for an ENI or instance exceeds the upper limit. |
404 | InvalidEcsId.NotFound | %s | The specified instance ID does not exist. |
404 | InvalidEniId.NotFound | %s | The specified ENI ID does not exist. |
404 | InvalidVSwitchId.NotFound | %s | The specified vSwitch does not exist. |
404 | InvalidSecurityGroupId.NotFound | %s | The specified security group ID does not exist. |
404 | InvalidOperation.PrimaryEniOnlySupportModifyNameAndDesc | Primary NetworkInterface is only allowed to modify name and description. | Primary ENIs can only have their names and descriptions modified. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
2024-01-24 | The Error code has changed. The request parameters of the API has changed | see changesets | ||||||||||||||
| ||||||||||||||||
2023-10-09 | The Error code has changed. The request parameters of the API has changed | see changesets | ||||||||||||||
| ||||||||||||||||
2023-06-14 | The Error code has changed | see changesets | ||||||||||||||
|