So I’m in the process of upgrading my Ubuntu machines (both local and through DO) from 22.04 to 24.04. The first point release is out (Sept 2024) and I’ve upgraded before. I specifically followed the instructions listed here: https://www.cyberciti.biz/faq/how-to-upgrade-from-ubuntu-22-04-lts-to-ubuntu-24-04-lts/. The upgrade process seems to work, however upon rebooting I can not ssh into the new installation or use the DO console. I’ve used the recovery ISO and chrooted into the installation however I’m not exactly sure where the error is. I’m guessing its a network issue however that’s really a guess. When things happen like this at home on VMs hosted within proxmox or xcp-ng, I’m able to obtain a console directly into the VM which really helps. The DO console seems to use a ssh connection, and if networking is down this ssh connection just doesn’t work. What’s the best strategy here to debug? I’ve rolled back to the last snapshot several times before performing the upgrade and I’m kind of stuck here on what to do. For networking I’m using a netplan config file with networkd as the renderer. I’m wondering if I should just write the systemd-network network files directly rather than depend on netplan (as I do within Arch), however I’m not quite sure this is going to fix things since I’m really missing some debug tools here.
Thanks for any suggestions.
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!
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.
Sign up for Infrastructure as a Newsletter.
Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
The issue for me was that networking was not configured correctly.
This stemmed from a defect in cloud-init 24.2.
I had to perform the following steps to resolve the issue:
From the Access tab on the Digital Ocean droplet launch Recovery Console
Edit /usr/lib/python3/dist-packages/cloudinit/net/netops/iproute2.py
Scroll to the bottom and find def flush_addr(interface: str)
Change:
to:
We’re only adding
"addr",
Reboot
From that point I was able to get valid network settings via cloud-init during the boot process.
If that doesn’t work for you then you can use the recovery console to manually setup a network interface following this post and troubleshoot further.
Did you ever figure this out?
Heya, @kevdog
I’ll also recommend to migrate your data to a new droplet using tools like
rsync
,scp
, FileZilla and etc. In this way you can assure that the droplet will not experience changes and protential problems during the OS upgrade.It is also a practical solution, especially if the current environment is proving too difficult to troubleshoot quickly. A fresh droplet also gives you a clean slate, free from the complexities and potential misconfigurations that might have occurred during the upgrade process.
Hope that this helps!