Skip to content

Instantly share code, notes, and snippets.

@markuszeller
Last active November 21, 2022 13:17
Show Gist options
  • Save markuszeller/44f67c1f2babaf5d521404934c357ae6 to your computer and use it in GitHub Desktop.
Save markuszeller/44f67c1f2babaf5d521404934c357ae6 to your computer and use it in GitHub Desktop.
Upgrade Ubuntu Dist from command line

Update

sudo apt update
sudo apt upgrade

Try to upgrade dist

sudo apt dist-upgrade
sudo apt autoremove

This could fail. Read the message. It will tell to edit a "prompt". Edit from LTS to normal.

sudo vim /etc/update-manager/release-upgrades

Repeat

sudo apt dist-upgrade
sudo apt autoremove

Finally upgrade

sudo do-release-upgrade

or enforce

sudo do-release-upgrade -d

Downgrade a package

Get a list of all available versions

apt search <package> -a | grep -i version

Install specific version (downgrade is possible)

sudo apt install <package>=<version>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment