Wiki Table of Contents

Upgrading from MX-19 to MX-21 without reinstalling

DISCLAIMER: This how-to is for the benefit of advanced users who are comfortable with the command line and willing to research and fix things if things go wrong, it’s not guaranteed to work and is not supported in any way by the dev team. As always, when upgrading from a Debian base to another one a clean install is the easiest procedure that provides a fresh and complete configuration. The upgrade might not work seamlessly, especially if you mixed and matched packages from Testing, Backports, and other unofficial repos.

WARNING 1: Users of the old Nvidia official driver should not upgrade. v.390 and up should be OK.
WARNING 2: Live users should not upgrade, this is only for installed systems.

IMPORTANT: Make sure you have enough free space on the root partition, you don’t want to be forced to stop the process in the middle of upgrade and have to recover from a broken state.

As always, before doing system-wide changes make a backup of your data and system.

Upgrade Steps:

  1. Change “buster” to “bullseye” /etc/apt/sources.list.d/ files, manually, or by running this command:
    sudo sed -i s/buster/bullseye/g /etc/apt/sources.list.d/*.list
  2. Add debian-security repo to debian.list (remove old entry):
    deb http://security.debian.org/debian-security bullseye-security main contrib non-free
  3. Install new mx repo key. Download and add it with this command:
    curl mxrepo.com/mx21repo.asc | sudo apt-key add -
  4. Run:
    sudo apt-get update
    make sure there are no errors and run:
    sudo apt full-upgrade
    When prompted to update config file keep local version for /etc/issue and /etc/grub.d/10_linux /etc/plymouth/plymouth, otherwise accept all the updates, with the exceptions of the ones you customized for yourself, /etc/sudoers for example — It’s recommended you check the diff: press ‘d’ and accept only if it makes sense: press ‘y’ to accept, press ‘n’ to preserve local version of the file.

If the upgrade stops in the middle of the operation it might be because some updates disabled the network. Make sure the network is back up and run “apt get full-upgrade” again till the command completes successfully.

  1. Install network-manager-sysvinit-compat (otherwise your network won’t connect automatically)
    sudo apt-get install network-manager-sysvinit-compat
  2. Run mx-boot-options and change default kernel to 5.10.0-8 (you can still boot to old kernel if for some reason that works better)
  3. Update /etc/mx-version and /etc/lsb-release change any MX-19.x strings to MX-21.
  4. Just to check whether everything was installed successfully, run “sudo apt full-upgrade” again.
  5. Reboot.

Optional, to make it look and behave like the official MX-21 (before or after reboot):

  1. Add DateTime plugin to panel (orage was removed in Bullseye)
  2. Add PulseAudio plugin to panel, remove volume plugin
  3. Install mx21-artwork (for wallpapers in /usr/share/backgrounds)
  4. Install papirus-mxblue, set it in Settings -> Appearance -> Icons
  5. Install matcha-themes, set matcha-azul in Settings -> Appearance -> Style
  6. Install and add xfce4-docklike-plugin to panel, remove Window Buttons
  7. Install mx21-archive-keyring

Cleanup (optional):
After a successful reboot run “sudo apt clean” to remove the cached .deb files.
sudo apt remove mx19-artwork mx19-archive-keyring
sudo apt autoremove (but make sure nothing useful is in the list of removable packages)
Remove old kernel if the new one works fine.

Potential issues:

  • icon missing for power-manager in system tray. Solution: add power-manager-plugin to the panel.

These instructions are for MX-19.x Xfce flavor, for KDE you can follow similar steps. You can skip the panel plugins steps, skip matcha-theme installation. Might need to remove some extra icons that show up on the desktop and panel.

EDIT: I disabled comments on this article, this is not the right place for support questions.

38 thoughts on “Upgrading from MX-19 to MX-21 without reinstalling”

  1. Bella guida,

    ho provato e sembra tutto OK

    ho eseguito anche il punto 15 (Installa e aggiungi xfce4-docklike-plugin al pannello, rimuovi i pulsanti della finestra), ma non capito cosa intendi per rimuovere i pulsanti della finestra.

    Comunque grazie 1000

    Riccardo

  2. “Disable debian-security repo from debian.list because it’s not yet available for Bullseye”
    Is this still relevant?

  3. Yes, there is, not sure how much stuff it’s in there, if anything. I understand new mesa stuff will make it to that repo and probably some newer kernels, right now AHS is not that relevant since Debian Stable is relatively new and it has relatively new kernels and packages.

  4. So I did the upgrade from MX 19 AHS KDE to MX 21.
    Everything went smooth.
    I had trouble with VirtualBox, it acted like it couldn’t find the linux-headers. So I reinstalled virtualbox from scratch, reinstalled kernel 5.10.0-8 and its headers, tried the virtualbox version in the test repo, and no go.
    In the end what worked was installing the antix kernel 5.10.52 offered in popular applications.

  5. Hi,
    Did the upgrade. Not sure if I made the correct choices when prompted to keep or update quite a few system configuration files, but seems ok.
    Only problem : the MX whisker icon is lost and I have the original mouse xfce icon.
    Any idea ?

  6. Hi. I did all the steps you mentioned in this thread. And everything went ok. However, after the upgrade, my keyboard response became slower than it was before. I don’t know why that happened. My previous version was MX Linux 19.4 KDE.

  7. Glad that you’re able to upgrade from MX 19 to MX 21. I always prefer a cleaner slate, so going to install MX 21 on another drive in my system and just go all fresh. Plus I’ll still have MX 19.4 Xfce on the sidelines just in case.

  8. Thank you for the instructions.

    One point though. EVERY major operating system supports upgrades when a new major version comes out. If I’m to install MX Linux on my parents PC, the explanation that they have to start from scratch and restore from backups as the recommended upgrade path is totally BOGUS.

    You don’t see Ubuntu telling it’s users to wipe and reinstall. You don’t see Red Hat, Fedora, or SUSE telling people the same thing.

    They ALL support upgrading major versions,

    WINDOWS supports upgrading to new major versions.

    If we want people to stay with MX, telling them there is no upgrade path is a BIG minus.

    • Which part of “Upgrading from MX-19 to MX-21 without reinstalling” is telling people “there is no upgrade path”?

      • This art: “Because of the change in the base from Debian 10 (Buster) to Debian 11 (Bullseye), there is no official upgrade option.”

        This path described on this page is not “officially” supported, nor is it a path viable for most grandpas or grandmas, not that MX-Linux is very well suited for that audience anyway.

        Last update I reorganized my drive to put /home on a separate partition so I could upgrade the OS easier.

        However, given the unstable state of my system I will reinstall from scratch. I’m struggling to isolate the cause of the instability, which is related to networking.

    • Bonjour. Que comprendre ?

      Pour moi MX Linux est une distribution semi-rolling. Du coup d’ailleurs, quelles différences avec une rolling (mise à jour en continu ; on est assuré d’avoir toujours la dernière version).
      Je pensais qu’une semi-rolling adoptait un fonctionnement voisin (avec une mise à jour auto vers la dernière version stable, à un moment donné. Tous les ans, tous les deux ans peu importe). Qu’en est-il ?

      Il n’y a pas de mise à jour automatique vers la dernière version stable quand elle est disponible ?
      Je viens de regarder; ma version est la MX-19.4 “patito feo”.

      Le seul moyen à terme, sera de réinstaller proprement une version supérieure quand celle-ci ne sera plus maintenue ? Ou d’utiliser cette (ce genre de) procédure ?

      Merci pour vos retours et explications !

      • Je pense pouvoir me répondre à moi-même 😉
        La version MX-19.4, datant du 31 mars 2021 à donc forcément été installé en “mise à jour vers une version supérieure” car ma première (et unique) intallation de MX Linux date d’avant.
        Possiblement du 11 juillet 2020 (soit initialement la MX-19.2 d’installée)
        https://en.wikipedia.org/wiki/MX_Linux

        Reste à savoir si la migration des “19” se feront sur le même principe vers les “21” (?)

  9. Thanks Adrian for the clear & concise upgrade instructions. I’ve been running, practically since it came out, MX19 with the Nvidia driver (problem coming…) for my old GEFORCE 750TI board. I was anxious to ‘upgrade in place’, having made many ‘tweaks’.

    I followed your upgrade instructions, and everything seemed to go well. Finally, however, I had lost my Nvidia drivers (470.63.01). In fact, the system re-booted to just the bare-bones frame-buffer video.

    I tried uninstalling Nvidia via “sudo ddm-mx -p nvidia”. After re-boot I was back to the Nouveau drivers.

    I then tried re-installing the Nvidia drivers, re-booted, and once again had bare-bones frame-buffer video.

    Well, I finally gave up, and restored MX19, with working Nvidia video, from my recent image backup.

    Any thoughts?

    -Richard (central USA)

  10. Didnt go well for me to upgrade (or doing a clean install) since I have a bit newer hardware: Nvidia Geforce 3060Ti, and Noveau probably wont yet support somewhat newer graphic cards for a year or three.
    After doing all above I rebooted and of course the Nvidia driver wasnt used. Instead it used “vesa” with low resolution. And using the driver updater in MX-tools doesnt do any good (neither when after doing a clean install) Networking didnt work after the upgrade either, but I guess that is because I chose to keep the old config when asked…
    So, I timeshifted back. (Thank God, the guy who wrote that piece of software!)

    You guys should really, really I mean REALLY consider offering proprietary driver for Nvidia during install, like Ubuntu does! I dont understand why it isnt offered. Maybe it will mess up MX because it is pure debian?

    • If you are referring to step 2 “Add debian-security repo to debian.list” that “deb …” is not a command, it’s what the entry in debian.list actually needs to look like.

      • thank you, yes i am. If it is not a command, how do i find the debian.list and how do i replace on it,
        Jesper

        • “This how-to is for the benefit of advanced users who are comfortable with the command line and willing to research and fix things if things go wrong”

          If you need to ask this question this tutorial is probably not for you, and you are better off doing a “clean install”. Also, this is not the best place to ask for support, it’s not a forum, it’s just an information page, for support and help post in the forum: forum.mxlinux.org

  11. Managed to get this working although my system can’t find:
    network-manager-sysvinit-compat
    mx21-artwork
    xfce4-docklike-plugin
    Think I got Network Manager working using the orphan-sysvinit-scripts, and starting Network Manager after a reboot. Now shows my, admittedly straightforward, wired connection in the system tray just fine.

    Thanks very much.

    • Just checked, they are in the repo:

      apt policy mx21-artwork network-manager-sysvinit-compat
      mx21-artwork:
      Candidate: 21.09.02
      Version table:
      21.09.02 500
      500 http://mxrepo.com/mx/repo bullseye/main amd64 Packages
      network-manager-sysvinit-compat:
      Candidate: 21.02.01
      Version table:
      21.02.01 500
      500 http://mxrepo.com/mx/repo bullseye/main amd64 Packages

      So, either you don’t have the right repo defined in /etc/apt/sources.list.d/mx.list (you might want to use mx-repo-manager to try a different mirror) or you don’t have the keychain that allows you to download packages from that repo.

      • Looked at my mx.list, was using the evowise mirror. Switched to a UK one, and got a load of updates, and the missing packages!

        Thanks very much 🙂

  12. This worked fine for me however there were a couple of small additional thing I had to change to ensure a successful system update. Also, I believe you made a small error/typo in your directions as well.

    – At the beginning you warn: “IMPORTANT: Make sure you have enough free space on the root partition, you don’t want to be forced to stop the process in the middle of upgrade and have to recover from a broken state.” How much free space is enough? I spent a couple of hours removing over 100 GB from my hdd just to be safe but I think this was overkill and we only need like… the size of the new packages that are downloaded… for me this was around 1.6 GB.

    • – In step 1 it was necessary for me to go into ALL repository list files to change “buster” to “bullseye” (and also “10” to “11” in some of them), not just in the sources.list but also in any custom repositories that I had added to my system for various applications that I have installed. Before changing ALL repository location names/lists a number of errors appeared for repositories that also needed to be updated ( for example a repository for Microsoft Visual Studio Code was still showing as “10”/ “buster” in the name and this caused an error). Make sure you update ALL/any custom repository location files and not just the standard ones.

      – In step 4, when comparing config files, it would be helpful if you could also tell people that they must type “q” to “quit” the “d” / “difference” comparison view and to return to the main prompt. I started pressing random keys attempting to exit that stupid view (“escape”, etc.) and was worried I was going to stop/break the whole update process. Press “q” to return to the prompt.

      • I had more comments to add (including a small typo in Adrian’s steps above) but whenever I try to post it this website’s annoying anti-spam filter thing kicks in and won’t let me post. I attempted to “email the administrator” as it instructs but that has gotten me nowhere.

        I’m up and running fine but the only strange thing I am now experiencing is that my fstab cifs auto drive mounts no longer happen at startup. My fstab hasn’t changed and if I manually enter the mount command into a terminal window everything mounts instantly/just fine. But for some reason nothing will mount automatically from the fstab as it did before I upgraded.

        Also, I really wish I could change the font color of the DateTime or Clock panel plug-ins… :-/

        • I don’t know if this is the correct way to fix this problem but I just went ahead and added “sudo mount -av” to a general startup script and now all of my drives probably mount again at startup.

  13. I have a separate home partition. Would it be possible to reinstall the latest version 21 of MX and not format the home partition? In other words would the previous version’s config files conflict with MX21?

    • You’ll not get exactly the same settings as somebody who installs MX-21 would, but I think most of the things should work. Some configurations have changed, you might have to add/remove/change some stuff to the panel (orage, pulseaudio).

Comments are closed.

MX Linux