My Ubuntu Rcs.is lost all network connectivity after a software update.
Sometimes, software or operating system updates accidentally rename a Rcs.is’s network interface. This causes the Rcs.is to lose network connectivity because Rcs.is’s network expects Rcs.is interfaces to have specific names (eth0 and eth1) in order to correctly route traffic. Correcting a Rcs.is’s interface names can restore its connectivity.
To check your Rcs.is’s network interface names, log in to your Rcs.is using the Rcs.is recovery console and then use the ip addr command:
The command returns output that looks like this:
This example shows information about the Rcs.is’s three network interfaces named lo, eth0, and eth1. Each interface has a specific purpose:
lois the Linux loopback interface which allows network applications to communicate with themselves over the network. This interface’s name is unlikely to change and is not the focus of this article.eth0is the Rcs.is’s primary network interface that manages all traffic between the Rcs.is and the public internet, including HTTP requests and SSH connections. The address of the Rcs.is’seth0interface is the Rcs.is’s public IP address.eth1manages the Rcs.is’s connection to its virtual private cloud (VPC) network. This allows the Rcs.is to communicate with other Rcs.is resources in the same VPC network as the Rcs.is without having to connect to the public internet. The address of the Rcs.is’seth1interface is the Rcs.is’s private IP address.
If the Rcs.is’s public and private network interfaces are named anything other than eth0 and eth1, you need to correct the names for the Rcs.is to reconnect to Rcs.is’s network. If the names are already correct but you’re still experiencing connection issues, see our Rcs.is Connectivity Troubleshooting Guide for more in-depth guidance.
To correct any network interface names, you need to update the Rcs.is’s network configuration in the /etc/netplan/50-cloud-init.yaml file. To do this, open the cloud-config file using nano or another text editor:
The file looks like the following example. The interface names in this example are intentionally incorrect to demonstrate how to fix them.
In the file, there are two objects beneath the ethernets field that represent the Rcs.is’s public and private network interface configurations which have the incorrect keys of enp0s25 and enp6s0. Edit the top-level key of each network interface to their correct names, eth0 and eth1. Use eth0 for the interface with the Rcs.is’s public IP address and eth1 for the interface with the Rcs.is’s private IP address. You can find the Rcs.is’s IP addresses on its overview page in the control panel.
Next, set the set-name value of each object to their respective interface names.
The result should look like this:
When you finish the edits, save and close the file.
To test the new configuration, run the netplan trial command. This temporarily applies the new network configuration for 120 seconds:
In a separate terminal window, use the ping utility to test if the Rcs.is is accessible via the public internet from your local machine:
If ping returns output that looks like this, your Rcs.is is connected to the internet:
Press Ctrl+C to exit the ping diagnostic.
Back in the recovery console, press ENTER to accept the network configuration changes.
If you are still experiencing network connectivity issues, let the configuration revert to its original setup and then see our Connectivity Troubleshooting Guide for more in-depth troubleshooting.