Installing a new Ubuntu version from scratch without any effort

Scenario: You have an existing Ubuntu installation and you want to install a newer version (e. g. Ubuntu 18.04) from scratch, i. e. drop the old installation completely and install the new version in place.

The trick/precondition which makes the installation effortless: On the current system, you already have your “/home” directory and your “/” (root) directory on different partitions. Then you can drop the old Ubuntu installation on the root partition and install the new Ubuntu version on this partition and the home partition can simply be adopted. If you don’t have your root directory and your home directory on different partitions, make a backup of your home folder and restore it later.

Prerequisites

  1. Important: Backup important data first!
  2. Download the latest Ubuntu release here: https://www.ubuntu.com/download/desktop

Let’s go: Create a bootable pen drive

Write the downloaded Ubuntu ISO file to a pen drive using dd (existing data on the pen drive will be lost after this process). First: Make sure that the pen drive is NOT mounted. Then: Open a terminal and login as root and call dd:

$ sudo su

# dd bs=50M if=/home/YOUR_NAME/Downloads/ubuntu-18.04.1-desktop-amd64.iso of=/dev/sdX && sync

Please change the path after “if=” to the path where the downloaded ISO file actually lies and change the path after “of=” to the device which represents your pen drive. You can use “lsblk” or “df -h” on the terminal to view your devices and spot your pen drive. It is really important to identify the correct device name as dd will overwrite existing partitions which can result in data loss if you aren’t cautious!

The installation

Now you have to boot from the newly created Ubuntu pen drive. Reboot your machine and select the pen drive as boot drive and boot from the pen drive. This step is a bit tricky (but not too hard) and differs from hardware to hardware. On Acer notebooks, you can try hitting F12 or F2 as described in this article.

When the pen drive is booted, you can follow the installation wizard most of the time. When it comes to partitioning: If you already have a separate “/” (root) and “/home” partition: Configure the old root partition as new root partition and check the format checkbox. Configure the old home partition as new home partition (do NOT check the format checkbox this time).

If you are asked whether to install proprietary software: choose NO. The proprietary things can mess up the whole system (at least this is what I experienced in the past).

When the installation is done: Confirm to reboot the machine and remove the pen drive when instructed.

Post-installation actions

Update the system

$ sudo su
# apt-get update
# apt-get upgrade

Install the multimedia codecs

$ sudo su
# apt-get install ubuntu-restricted-extras

Install support for encrypted DVDs

So as to play encrypted DVDs you have to install the package libdvdcss2 which is not in the official repositories. That’s why you have to add a new repository to your “/etc/apt/sources.list”. Just add the following line:

deb https://download.videolan.org/pub/debian/stable/ /

Then run:

$ wget -O - https://download.videolan.org/pub/debian/videolan-apt.asc | sudo apt-key add -

…and finally install the package:

# apt-get update
# apt-get install libdvdcss2

If you still cannot watch DVDs, try to disable the DVD menu in VLC media player: “Media | Open Media (Ctrl+D)” and check “No disc menu” and click on “Playback”.

Hints: http://www.videolan.org/developers/libdvdcss.html

Remove Amazon app

Open Ubuntu Software Center, go to tab “Installed” and click on remove next to the Amazon app.

Enabling the touchpad of your notebook

If your touchpad does not work out of the box then go to “System settings | Devices” and enable your touchpad.

Install your favourite software

apt-get install clementine keepass vlc zim...