This article introduces how to attach an elastic network adapter (ENI) to a private network (VPC) type instance, and focuses on the specific steps. The content of this article is compact, and I hope you can gain something.
AttachNetworkInterface
Description
The elastic network card must be in the available (Available) state.
The instance must be in Running or Stopped status.
Elastic network cards can only be attached to VPC type instances and must be in the same VPC as the instance.
An elastic network card can only be attached to one instance at the same time.
One instance can be attached to multiple elastic network cards at the same time. Please refer to Elastic Network Cards to view the number of elastic network cards that can be attached to each instance specification.
Since VPC virtual switches cannot span across availability zones, the instance to which the elastic network adapter is attached and the switch where the elastic network adapter is located must belong to the same availability zone.
Request parameters
##Return parameters
are all public return parameters. See Public Parameters.Example
Request example
https://ecs.aliyuncs.com/?Action=AttachNetworkInterface &RegionId=cn-hangzhou &NetworkInterfaceId=[networkInterfaceId] &InstanceId=AY121018033933eae8xxxxx &<公共请求参数>
Return example
XML format
<AttachNetworkInterfaceResponse> <RequestId>04F0F334-1335-436C-A1D7-6C044FExxxxx</RequestId> </AttachNetworkInterfaceResponse>
JSON format
{ "RequestId": "04F0F334-1335-436C-A1D7-6C044FExxxxx" }
Error code
The following are error codes unique to this interface. For more error codes, please visit the API Error Center.The above is the detailed content of How to attach an elastic network interface (ENI) to a private network (VPC) type instance. For more information, please follow other related articles on the PHP Chinese website!