After a public NAT gateway is created, add an SNAT rule, so that servers in a VPC subnet or servers that are connected to a VPC through Direct Connect can access the Internet by sharing an EIP.
One SNAT rule takes effect for only one subnet. If there are multiple subnets in a VPC, add multiple SNAT rules to allow servers in the subnets to share an EIP.
in the upper left corner and select the desired region and project.
to expand the service list and choose Network > NAT Gateway.The Public NAT Gateways page is displayed.
Parameter | Description |
|---|---|
Scenario | The scenarios where the SNAT rule is used Select VPC if your servers in a VPC need to access the Internet. Select Direct Connect if servers in your on-premises data center need to access the Internet. |
CIDR Block | In a VPC scenario, specify a VPC subnet to enable servers in that subnet to access the Internet using the SNAT rule. In a Direct Connect scenario, specify a CIDR block of your data center to enable your servers to access the Internet using the SNAT rule. |
Public IP Address Type | The EIP used for accessing the Internet You can select an EIP that either has not been bound, has been bound to a DNAT rule of the current public NAT gateway with Port Type set to Specific port, or has been bound to an SNAT rule of the current public NAT gateway. You can select up to 20 EIPs for an SNAT rule. If you have selected multiple EIPs for an SNAT rule, one EIP will be chosen randomly. |
Monitoring | You can create alarm rules on the Cloud Eye console to monitor your SNAT connections and keep informed of any changes in a timely manner. |
Description | Provides supplementary information about the SNAT rule. Enter up to 255 characters. Angle brackets (<>) are not allowed. |