Attaching an FNI to an Instance
You can attach flexible network interfaces (FNIs) to an instance of the same Virtual Private Cloud (VPC), placed in any subnet of the same Availability Zone (AZ) as the FNI. Attaching FNIs to an instance partitions its network.
This action updates the state of the FNI from available
to in-use
. For more information, see About FNIs > FNIs Attachment to Instances.
The number of maximum FNIs you can attach to an instance depends on the used instance type used. For more information, see Instance Types.
Attaching an FNI to an Instance Using Cockpit v1
-
Click Network/Security > Flexible Network Interfaces.
-
Click the FNI you want to attach to an instance.
The FNI is selected. -
Click Attach .
The ATTACH INSTANCE TO FNI dialog box appears. -
From the Instance list, select the instance you want to attach the FNI to.
-
In the Device field, type the device index for the FNI attachment (between 1 and 7, both included).
-
Click Attach to validate.
The FNI is attached to the selected instance.
If you are attaching an FNI to a running instance, the network interface may not automatically be configured inside the instance. Therefore, you must either restart the instance, or configure the network interface manually as follows:
|
Linking a NIC to a VM Using Cockpit v2-beta
-
Click inside the NICs dashboard to make checkboxes appear.
-
Check the box of the NIC you want to link to a VM.
The NIC is selected and an action menu appears. -
Click
Link to VM.
The LINK VM TO NIC dialog box appears. -
From the VM list, select the VM you want to link the NIC to.
-
In the Device field, type the device index for the NIC link (between 1 and 7, both included).
-
Click Link.
The NIC is linked to the VM.
If you are linking a NIC to a running VM, the network interface may not automatically be configured inside the VM. Therefore, you must either restart the VM, or configure the network interface manually as follows:
|
Linking a NIC to a VM Using OSC CLI
See the LinkNic command sample in the documentation of the OUTSCALE API. |
Attaching an FNI to an Instance Using AWS CLI
To attach a FNI to an instance, use the attach-network-interface command following this syntax:
$ aws ec2 attach-network-interface \
--profile YOUR_PROFILE \
--network-interface-id eni-12345678 \
--instance-id i-87654321 \
--device-index 2 \
--endpoint https://fcu.eu-west-2.outscale.com
This command contains the following attributes that you need to specify:
-
(optional)
profile
: The named profile you want to use, created when configuring AWS CLI. For more information, see Installing and Configuring AWS CLI. -
network-interface-id
: The ID of the FNI to attach. -
instance-id
: The ID of the instance to which you want to attach the FNI. -
device-index
: The device index for the FNI attachment (between 1 and 7, both included). -
endpoint
: The endpoint corresponding to the Region you want to send the request to.
The attach-network-interface command returns the following element:
-
AttachmentId
: The ID of the attachment operation.
{
"AttachmentId": "eni-attach-1234abcd"
}
The FNI is attached to the specified instance.
If you are attaching an FNI to a running instance, the network interface may not automatically be configured inside the instance. Therefore, you must either restart the instance, or configure the network interface manually as follows:
|
Related Pages
Corresponding API Methods
AWS™ and Amazon Web Services™ are trademarks of Amazon Technologies, Inc or its affiliates in the United States and/or other countries.