5

I use Lubuntu 22.04 LTS on my computer, and am testing grub editing.

It seems Lubuntu is using some kind of graphical interface to show grub. enter image description here

Can I disable it to use the same as Ubuntu's default?

Here's is my grub config file : cat /etc/default/grub

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#   info -f grub -n 'Simple configuration'

GRUB_DEFAULT="0" GRUB_TIMEOUT_STYLE="hidden" GRUB_TIMEOUT="0" GRUB_DISTRIBUTOR="lsb_release -i -s 2> /dev/null || echo Debian" GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" GRUB_CMDLINE_LINUX="" GRUB_DISABLE_OS_PROBER="false"

Uncomment to enable BadRAM filtering, modify to suit your needs

This works with Linux (no patch required) and with any kernel that obtains

the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)

#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

Uncomment to disable graphical terminal (grub-pc only)

#GRUB_TERMINAL="console"

The resolution used on graphical terminal

note that you can use only modes which your graphic card supports via VBE

you can see them in real GRUB with the command `vbeinfo'

#GRUB_GFXMODE="640x480"

Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux

#GRUB_DISABLE_LINUX_UUID="true"

Uncomment to disable generation of recovery mode menu entries

#GRUB_DISABLE_RECOVERY="true"

Uncomment to get a beep at grub start

#GRUB_INIT_TUNE="480 440 1"

These are the results of update-grub

Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/init-select.cfg'
Sourcing file `/etc/default/grub.d/lubuntu-grub-theme.cfg'
Generating grub configuration file ...
Found theme: /usr/share/grub/themes/lubuntu-grub-theme/theme.txt
Found linux image: /boot/vmlinuz-5.15.0-39-generic
Found initrd image: /boot/initrd.img-5.15.0-39-generic
Found linux image: /boot/vmlinuz-5.15.0-25-generic
Found initrd image: /boot/initrd.img-5.15.0-25-generic
Memtest86+ needs a 16-bit boot, that is not available on EFI, exiting
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
Found Windows Boot Manager on /dev/sda4@/efi/Microsoft/Boot/bootmgfw.efi
Adding boot menu entry for UEFI Firmware Settings ...
done

I can see it pointing thos two files: `/etc/default/grub.d/lubuntu-grub-theme.cfg' /usr/share/grub/themes/lubuntu-grub-theme/theme.txt

Should the solution be to delete the /usr/share/grub/themes/lubuntu-grub-theme/theme.txt so it doesn't load it ? Will this work ?

3 Answers3

6

The appearance of grub is managed by /etc/grub.d/05_debian_theme. Remove the executable bit from this file with sudo chmod -x /etc/grub.d/05_debian_theme

Create the file /etc/grub.d/04_set-colors with the following content:

#!/bin/sh
set -e

Set the colors of the boot-menu. Available colors are

black

blue

green

cyan

red

magenta

brown

light-gray

dark-gray

light-blue

light-green

light-cyan

light-red

light-magenta

yellow

white

echo "${1}set menu_color_normal=white/black" echo "${1}set menu_color_highlight=black/light-gray"

Make the file executable with sudo chmod +x /etc/grub.d/04_set-colors

Finally run sudo update-grub.

This will give you a very basic grub menu with black background and text- and hilight-colors of your choice.

You can easily undo the changes by removing the newly created file /etc/grub.d/04_set-colors, giving the executable bit back to /etc/grub.d/05_debian_theme and, of course, running sudo update-grub again.

mook765
  • 18,644
4

Solution:

I've been able to remove the theme by removing the packet with:

apt purge lubuntu-grub-theme.

I had to update-grub, otherwise I got this a message before the grub menu:

/usr/share/grub/themes/lubuntu-grub-theme/theme.txt not found

I confirm the answer from @guiverc and I added the release version like he/she suggested.

1

Recently I have been dealing with this. I am running 22.04.3 LTS. I found that all you need to do is comment out the line in /etc/default/grub.d/lubuntu-grub-theme.cfg then run sudo update-grub and reboot.

The following commands will comment out all the lines in the /etc/default/grub.d/lubuntu-grub-theme.cfg, then update the grub.

sudo sed -i 's/^/# /' /etc/default/grub.d/lubuntu-grub-theme.cfg
sudo update-grub
reboot
Terrance
  • 43,712