When trying to update Ubuntu 22.04 to 24.04 I ran into a problem: my computer shut down in the middel of the upgrade process… and yes, stuff did not work.
Fixing the issue was not easy as the normal steps to solve this, mentioned on other sites did not work: “There is a temporary DNS issue.” This meant that I had internet access, but hostnames like archive.ubuntu.com could not be resolved.
To solve this, I needed to install the dns-resolve software as the packages was not yet reinstalled during the update process. However, I could not do this because the package manager could not get the packages downloaded as it could not resolve archive.ubuntu.com, where the files are stored.
To be able to download the dns resolver, I had to change the /etc/apt/sources.list file and change the xx.archive.ubuntu.com parts into the ip addresses of the server, as well as the security.ubuntu.com parts. To get the proper IP address, you can try to ping these servers on another computer.
After that, fixing worked just find, but my DNS kept being an issue. I needed to manually install the resolv-package: sudo apt install resolv*
Do not forget to change the /etc/apt/sources.list to the original xx.xxx.ubuntu.com values from the ip addresses you entered.
Leave a Reply