Upgrading from one Debian version to the next major version is usually very smooth and can be done without much effort. However, you should always bear in mind that you should only upgrade from one Debian version to the next, e.g. from 10 to 11 and never directly from 9 to 11. Always perform upgrades one after the other and always restart the server after reaching a new version (e.g. when upgrading from 9 to 10 and then again when upgrading from 10 to 11 is completed).
Depending on the speed of the server, an upgrade of the Debian version takes about 15 minutes.
To perform the upgrade, please follow the steps below:
- Update the file /etc/apt/sources.list (replace buster with bullseye here). Please also note that the archive for security updates has a new address, which should now be
deb https://security.debian.org/debian-security bullseye-security main
- If you have other repro files under /etc/apt/sources.list.d, please also adjust them accordingly
- Execute the command apt update
- Execute the command apt upgrade
- execute the command apt full-upgrade. If you are asked in the course of the upgrade whether some existing configuration files should be replaced, in most cases it is better to keep the old files (answer no).
- Run the command apt-get autoremove to remove all packages that are no longer needed and free up the disk space.
- In order to load the new kernel and kernel modules, please restart the server
After the server has booted up again, the upgrade to the new Debian version is complete. Now check whether all services are working and check the logs if necessary.