I will use term "source version" for the version that you have used before upgrading and the "destination version" for the version that you have used after upgrading.
Ways of upgrading Ubuntu versions:
Commonly called Debian way of upgrading or sometimes, The Brute Force Method.
This way:
- Makes your system supplied by packages of destination version.
- Some third-party repositories might not have the channel for destination version, so you occasionally encounter unmet dependencies problem and in all cases you cannot upgrade the packages to newer version. (For example,
wine-hq
repository only recently added support for Bionic).
- You will not be able to complete updating your repository without removing third-party repositories, as you will experience
404 Not found
error.
Some notes: Disable third-party repository.
Works: It either works or not.
Recommendation level: too low.
Commonly called Ubuntu way of upgrading:
This way:
- For repositories:
- Switches to
sources.list
new repository entries
- Automatically removes obsolete entries
- For packages:
- Removes possible broken packages
- Updates packages index (equivalent to
sudo apt full-upgrade
)
- Upgrades system (equivalent to
sudo apt full-upgrade
)
- Removes old packages:
- Old kernels
- Packages existed in the source version of Ubuntu, but not existed in the destination version.
- Deals with Nvidia Drivers.
- Release specific jobs:
- Plays with some configurations
- Runs release specific scripts:
- For example, replaces Unity Desktop with Gnome Desktop.
However, a lot of people are experiencing problems with do-release-upgrade
:
Works: It works... with bugs.
Recommendation level: between low and middle.
This is the most recommended way of upgrading your system.
Note #1: Do not forget to Backup.
Note #2: You will most likely spend equal time to fix errors called by above-mentioned methods. If so, why hesitating to do a clean installation?
Works: Always works.
Recommendation level: very high.
sudo apt-get dist-upgrade
(or bettersudo aptitude dist-upgrade
) to involve new dependencies into upgrade process. Warning message about apt in scripts is normal, it exists in both 16.04 an 18.04. – N0rbert Aug 01 '18 at 13:59dist-upgrade
would be a better option but again, willsudo apt-get install -f
install dependencies? – Kulfy Aug 01 '18 at 14:02man apt
in the section titled "SCRIPT USAGE AND DIFFERENCES FROM OTHER APT TOOLS" – DK Bose Dec 28 '18 at 16:39