Inclusion of DE in GRUB menu items

Got multiple Manjaro versions with multiple DEs, just wondering the easiest way to include the DE in the grub menu entries for easy identification. Where does os-prober read the distro name from within update-grub?

I tried changing /etc/lsb-release


and running update-grub, but still generates menu entries with Manjaro Linux, not Manjaro Linux KDE.

If you just want to edit the Manjaro Linux entry from your grub startup menu, the easiest way to do is by editing GRUB_DISTRIBUTOR string in your /etc/default/grub and run sudo update-grub after it. For example :


Doing this will make Manjaro KDE Linux appear in your grub startup menu. bu this will not alter other menuentry in GRUB menu besides the OS that provide the grub

(If you want and wonder how to remove the word Linux completely please read at note in the end)

Another way of doing this is to edit /boot/grub/grub.cfg and look for menuentry and edit the string next to it, for example :

menuentry 'Manjaro Linux'


menuentry 'Manjaro KDE Linux'

Note: This method is very dirty and will lose upon next update-grub command

The harder way

update-grub is just a command to automatically generate a /boot/grub/grub.cfg using template /etc/grub.d and settings from /etc/default/grub.

How os-prober handled is defined in grub template folder ( Most likely in /etc/grub.d/30_os-prober). If you want to alter how os-prober is used, you can try editing /etc/grub.d/30_os-prober

Sadly, I don’t know how to edit the grub template for handling naming multiple manjaro version, but you can try for yourself!

If you’re wondering how to remove Linux string completely, just edit /etc/grub.d/10_linux and remove the Linux string in OS="${GRUB_DISTRIBUTOR} Linux" from this function :

if [ "x${GRUB_DISTRIBUTOR}" = "x" ] ; then
  CLASS="--class $(echo ${GRUB_DISTRIBUTOR} | tr 'A-Z' 'a-z' | cut -d' ' -f1|LC_ALL=C sed 's,[^[:alnum:]_],_,g') ${CLASS}"

I haven’t tried this for some time (because I use this), but suppose your ‘default grub’ is from OS ‘A’, and it boots OS ‘B’ and ‘C’ and…

Then changing 'GRUB_DISTRIBUTOR=“Manjaro KDE” in OS ‘A’ will change description of OS ‘A’ entry in OS ‘A’ grub menu. To change descritption of OS ‘B’ and OS ‘C’ in OS ‘A’ grub menu, then you need to go to OS ‘B’ and change “/etc/lsb-release” in OS ‘B’ and so on.
Then ‘update-grub’ in OS ‘A’.

Hope I get this correct and good luck.

1 Like

Yep, I should have thought more before creating this thread, is very straight forward.

Simple as editing /etc/default/grub for bootloader OS, and /etc/lsb-release for other OSes probed and added during update-grub.

Would need to re-edit if lsb-release is updated with new OS version.


1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.

Forum kindly sponsored by Bytemark