Question

Upgrading Ubuntu 20.x -> 22.x killed my network

I’ve spent the last several hours trying to figure out what’s going on, but I’m totally stuck.

I was trying to upgrade my droplet from Ubuntu 20.x to Ubuntu 22.x using this guide. Now my networking doesn’t work.

  • I can only access the droplet through the recovery terminal, so copy-pasting details is not possible.
  • When using the terminal, I can ping localhost, but I can’t ping the gateway.
  • DNS doesn’t work because the network is totally unreachable.
  • ufw status shows ssh port is LIMIT IN from Anywhere and: deny (incoming), allow (outgoing), disabled (routed).
  • /etc/netplan/50-cloud-init.yaml file shows one entry for “ens3”.
  • “ip a” shows two interfaces: “lo” (state UNKNOWN) and “ens3” (state UP).
  • “ip route” does not return anything.

How do I troubleshoot this?

Thanks for any help!

  • Andy

Submit an answer
Answer a question...

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Accepted Answer

To answer my own question via DO support (thanks Mubashir!)…

The issue was with “systemd’s predictable network interface naming”.

The solution was to turn it off via GRUB.

  • edit /etc/default/grub.d/50-cloudimg-settings.cfg and add net.ifnames=0 at the end of GRUB_CMDLINE_LINUX_DEFAULT:

GRUB_CMDLINE_LINUX_DEFAULT=“console=tty1 console=ttyS0 net.ifnames=0”

  • then:

update-grub

reboot