Why Can't My ECS Access the Internet Even After an EIP Is Bound?
Symptom
An ECS with an EIP bound cannot access the Internet.
Troubleshooting
Checking Whether EIPs Are Blocked or Frozen
- Check whether the EIP is blocked. For details, see How Do I Unblock an EIP?
- Check whether the EIP is frozen. For details, see Why My EIPs Are Frozen? How Do I Unfreeze My EIPs?
Checking EIP Connectivity
Figure 1 shows the networking diagram for an ECS to access the Internet using an EIP.
Locate the fault based on the following procedure.

- Step 1: Check Whether the ECS Is Running Properly
- Step 2: Check Whether the Network Configuration of the ECS Is Correct
- Step 3: Check Whether an EIP Has Been Assigned and Bound to the ECS
- Step 4: Check Whether an EIP Is Bound to the Primary Network Interface of the ECS
- Step 5: Check Whether Required Security Group Rules Have Been Configured
- Step 6: Check Whether Traffic from the ECS Subnet Is Blocked
Step 1: Check Whether the ECS Is Running Properly
Check the ECS status.
If the ECS status is not Running, start or restart the ECS.

Step 2: Check Whether the Network Configuration of the ECS Is Correct
- Check whether the ECS's network interface has an IP address assigned.
Log in to the ECS, and run ifconfig or ip address to check the IP address of the ECS's network interface.
- Check whether the ECS's network interface has a virtual IP address.
Log in to the ECS, and run ifconfig or ip address to check whether the ECS's network interface has a virtual IP address. If the ECS's network interface has no virtual IP address, run the ip addr add <virtual-IP-address> eth0 command to configure an IP address for the ECS's network interface.
Figure 4 Virtual IP address of a network interfaceCheck whether the ECS's network interface has a default route. If there is no default route, run ip route add to add one.
Figure 5 Default route
Step 3: Check Whether an EIP Has Been Assigned and Bound to the ECS
Check whether an EIP has been assigned and bound to the ECS. If no EIP has been assigned, assign an EIP and bind it to the ECS.
Step 4: Check Whether an EIP Is Bound to the Primary Network Interface of the ECS
Check whether an EIP is bound to the primary network interface of the ECS. If there is no EIP bound to the primary network interface of the ECS, bind one.
You can view the network interface details by clicking the Network Interfaces tab on the ECS details page. By default, the first record in the list is the primary network interface.

Step 5: Check Whether Required Security Group Rules Have Been Configured
For details about how to add security group rules, see Adding a Security Group Rule.
If security group rules have not been configured, configure them based on your service requirements. (The remote IP address indicates the allowed IP address, and 0.0.0.0/0 indicates that all IP addresses are allowed.)
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.