do-upgrade-release
I was upgrading my server to ubuntu 20.04 when I came across the issue where
sudo do-upgrade-release
failed. Based off stackoverflow and other people's experiences, the command is either magic and works like a charm
or it's pretty broken.
The solution I ended up doing was changing my sources list, which is found at:
/etc/apt/sources.list
The problem was that do-upgrade-release
was not updating the sources list, so it couldn't find any of 20.04's packages.
If you do sudo vim /etc/apt/sources.list
Then all of the lines are formatted like
# Required
deb http://old-releases.ubuntu.com/ubuntu/ CODENAME main restricted universe multiverse
deb http://old-releases.ubuntu.com/ubuntu/ CODENAME-updates main restricted universe multiverse
deb http://old-releases.ubuntu.com/ubuntu/ CODENAME-security main restricted universe multiverse
# Optional
#deb http://old-releases.ubuntu.com/ubuntu/ CODENAME-backports main restricted universe multiverse
Change the codename from your old OS to your new OS. In my case, I had to change it to focal
for focal fossa.
This is apparently the "hacky," "Debian" way to do it that Ubuntu has been trying to avoid doing. However, sometimes stuff just doesn't work.
Other solutions I've seen are to run
apt dist-upgrade
But I've never used that and can't verify that it works.