Deleting a NAT Gateway
You can delete a specified NAT gateway that you no longer need.
This action disassociates the External IP (EIP) from the NAT gateway, but does not release this EIP from your account. It does not delete any NAT gateway routes in your route tables.
Deleting a NAT Gateway Using Cockpit v1
-
Click VPC > NAT Gateways.
-
Click the NAT gateway you want to delete.
The NAT gateway is selected.Multiselection is available.
-
Click Delete NAT Gateway .
The DELETE NAT GATEWAY(S) dialog box appears. -
Click Delete to validate.
The NAT gateway is deleted.Deleted resources remain visible for 1 hour.
Deleting a NAT Service Using Cockpit v2-beta
-
Click inside the NAT Services dashboard to make checkboxes appear.
-
Check the box of the NAT service you want to delete.
The NAT service is selected and an action menu appears. -
Click
Delete.
The DELETE NAT SERVICE dialog box appears. -
Click Delete NAT Service(s).
The NAT service is deleted.Deleted resources remain visible for 1 hour.
Deleting a NAT Service Using OSC CLI
See the DeleteNatService command sample in the documentation of the OUTSCALE API. |
Deleting a NAT Gateway Using AWS CLI
To delete a NAT gateway, use the delete-nat-gateway command following this syntax:
$ aws ec2 delete-nat-gateway \
--profile YOUR_PROFILE \
--nat-gateway-id nat-12345678 \
--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. -
nat-gateway-id
: The ID of the NAT gateway. -
endpoint
: The endpoint corresponding to the Region you want to send the request to.
The delete-nat-gateway command returns the following element:
-
NatGatewayId
: The ID of the NAT gateway.
{
"NatGatewayId": "nat-12345678"
}
The NAT gateway is deleted.
Deleted resources remain visible for 1 hour. |
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.