Get Started of NAT Gateways
Last updated: 2019-12-14 10:14:15PDF
By creaing an NAT gateway, you can connect a private-network CVM to the Internet.
1) Create NAT gateway
You can use CreateNatGateway API to purchase a NAT gateway. This API will return an order number, and you can use QueryNatGatewayProductionStatus API to query the information of purchased NAT gateway.
2) Modify routing table
Modify the routing table policy using the ModifyRouteTableAttribute API. Add a routing policy that will direct the next hop that needs to access the Internet through NAT gateway to the NAT gateway.
3) Modify routing table associated with subnet
After the routing policy is configured, you can use the AssociateRouteTable API to direct the subnet that needs to access the Internet through NAT gateway to the routing table.
For more information about specific usage scenarios of NAT gateway, refer to NAT Gateway Description