Ubuntu

How to Upgrade Ubuntu 18.04 LTS to Ubuntu 20.04 LTS

How to Upgrade Ubuntu 18.04 LTS to Ubuntu 20.04 LTS
In this article, I am going to show you how to upgrade Ubuntu Desktop 18.04 LTS to Ubuntu Desktop 20.04 LTS and Ubuntu Server 18.04 LTS to Ubuntu Server 20.04 LTS. So, let's get started.

Upgrading Ubuntu Desktop 18.04 LTS to 20.04 LTS:

If you're using Ubuntu Desktop 18.04 LTS and would like to upgrade to Ubuntu Desktop 20.04 LTS, then this section is for you.

First, open Software & Updates app from the Application Menu of Ubuntu 18.04 LTS.

Now, make sure all the marked checkboxes are checked in the Ubuntu Software tab.

You may also want to change the Ubuntu mirror to Main server if you're having problems with the later section of this article. Because, the updates may not be immediately available to your closest mirror. It may take time for the updates to propagate to all the Ubuntu official mirrors.

Now, go to the Updates tab. Make sure all the marked checkboxes are checked.

Also make sure that Notify me of new Ubuntu version is set to For long-term support versions.

Then, close the Software & Updates app.

Before you upgrade to Ubuntu 20.04 LTS, you should update all the existing packages of your Ubuntu 18.04 LTS to the latest available versions.

To do that, open the Software Updater app from the Application Menu of Ubuntu 18.04 LTS.

The Software Updater app should check for new updates.

All the available updates should be displayed. Click on Install Now.

Type in your login password and click on Authenticate.

The updates are being downloaded and installed. It may take a while depending on the speed of your internet.

Once the updates are installed, click on Restart Now.

Once your computer boots, open a Terminal (press + + T) and run the following command:

$ update-manager -c -d

Software Updater should display the message Ubuntu 20.04 is now available. Click on Upgrade…

Now, type in your login password and click on Authenticate.

Ubuntu 20.04 LTS release notes should be displayed. Now, click on Upgrade.

Ubuntu 18.04 LTS is being prepared for the upgrade. It may take a while.

Click on Start Upgrade.

Click on Close.

The upgrade should start. It may take a while to complete depending on the speed of your internet connection.

Ubuntu 18.04 LTS is being upgraded to Ubuntu 20.04 LTS.

Ubuntu 18.04 LTS is being upgraded to Ubuntu 20.04 LTS.

Ubuntu wants to remove packages that are not supported in Ubuntu 20.04 LTS. Click on Remove to remove them.

The unsupported packages are being removed.

Once the upgrade is complete, click on Restart Now.

Your Ubuntu 18.04 LTS machine should be upgraded to Ubuntu 20.04 LTS. Enjoy!

Upgrading Ubuntu Server 18.04 LTS to 20.04 LTS:

If you want to upgrade Ubuntu Server 18.04 LTS to Ubuntu Server 20.04 LTS, then this section is for you.

First, update the APT package repository cache with the following command:

$ sudo apt update

As you can see, 23 packages can be upgraded.

It's best to upgrade all the existing packages to their latest versions before attempting to upgrade to Ubuntu 20.04 LTS.

Upgrade all the packages of your Ubuntu 18.04 LTS machine with the following command:

$ sudo apt full-upgrade

Now, press Y and then press .

The updates are being installed.

At this point, the package upgrade should be complete.

Now, reboot your Ubuntu Server 18.04 LTS machine with the following command:

$ sudo reboot

Now, to make sure that update-manager-core is installed, run the following command:

$ sudo apt install update-manager-core -y

In my case, it is already installed.

Now, check whether you can upgrade to Ubuntu 20.04 LTS with the following command:

$ sudo do-release-upgrade

It may report that There is no development version of an LTS available. If that's the case, you have to run do-release-upgrade command with the -d flag.

Run do-release-upgrade with the -d flag as follows:

$ sudo do-release-upgrade -d

do-release-upgrade is checking for new Ubuntu release (Ubuntu 20.04 LTS in this case).

If you're attempting to upgrade your Ubuntu Server 18.04 LTS over SSH (as I am), then you have to allow the updater to run an SSH server on port 1022. In case, the upgrade fails and you are unable to access your Ubuntu Server 18.04 LTS over SSH (port 22), then you will be able to connect to the backup SSH server running on port 1022.

To confirm that, press Y and then press .

If your Ubuntu Server 18.04 LTS has firewall configured to block port 1022, then open another SSH session and run the following command to allow access to the port 1022:

$ sudo ufw allow 1022/tcp

Then, press to continue.

The package repository information is being updated.

Now, it should show you a summary of the upgrade. As you can see, 17 packages are not officially supported anymore. 3 packages are going to be removed. 133 new packages will be installed and 450 packages will be upgraded. In total, about 336 MB of data will be downloaded from the internet. The numbers will be different for you.

Anyway, to continue the upgrade, press Y and then press .

All the required packages are being downloaded. It may take a while to complete depending on the speed of your internet connection.

The updates are being installed.

You will be asked to pick an LXD version. If you don't care (leave 4.0 - the default version), just press .

The upgrade should continue.

If you have edited some configuration files, you will be asked whether you want to keep the version you currently have or replace it with the version that comes by default with the update (the package maintainer version). The default action is to keep the version you already have.

In this case, I have modified the /etc/nanorc file. The default action N or O will keep you keep the /etc/nanorc file you already have.

If you select Y or I, then the /etc/nanorc file will be replaced by the one provided by the updated package.

You can select D to see the difference between these 2 versions before you decide which version to keep.

I am going to keep the version that I have. So, I am just going to press .

NOTE: You should keep the version you have. Otherwise, the configuration you've done will be lost. For example, if you have configured an Apache web server, and you replaced the configuration file with the package maintainer version, then you will have to reconfigure your Apache webserver after the upgrade. I am sure, you don't want that.

You may see this type of prompt many times. Pick the option that you think is the best for you and press .

Now, you will be asked to remove the obsolete (unsupported packages). To confirm, press Y and then press .

The obsolete packages are being removed.

Once the upgrade is complete, you will be asked to restart your server. Press Y and then press .

Enjoy Ubuntu Server 20.04 LTS once your server boots.

So, this is how you upgrade Ubuntu 18.04 LTS to Ubuntu 20.04 LTS. Thanks for reading this article.

Control & manage mouse movement between multiple monitors in Windows 10
Dual Display Mouse Manager lets you control & configure mouse movement between multiple monitors, by slowing down its movements near the border. Windo...
WinMouse lets you customize & improve mouse pointer movement on Windows PC
If you want to improve the default functions of your mouse pointer use freeware WinMouse. It adds more features to help you get the most out of your h...
Mouse left-click button not working on Windows 10
If you are using a dedicated mouse with your laptop, or desktop computer but the mouse left-click button is not working on Windows 10/8/7 for some rea...