Skip to content

How to upgrade Ubuntu server 20.04 to Ubuntu 22.04 (latest)

1. Let’s fetch the latest version of the package list from the repositories.

sudo apt update

2. Upgrade the installed packages.

sudo apt upgrade

3. Upgrade the distribution and reboot the server.

sudo apt dist-upgrade
sudo reboot

4. Let’s make sure we have the Update Manager Core installed.

sudo apt install update-manager-core

5. Let’s make sure we upgrade to only the latest lts version.
make sure `prompt` is set to lts
prompt=lts

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

6. Now upgrade the server.

sudo do-release-upgrade -d

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.