Meet a problem when I turn off the 30_os-prober script

I added some custom menus to my grub2 boot menu, then I want to disable 30_os-prober script to keep my boot menu clean.
The problem is when I set GRUB_DISABLE_OS_PROBER=true in the grub config file or use the command “sudo chmod -x /etc/grub.d/30_os-prober”,then run the command ''sudo update-grub", after reboot the computer, it will not show the grub interface anymore, instead, it keeps a black screen for almost 30 seconds and direct go into manjaro boot interface. If I revoke the operation, it will become normal.
I want to know what caused this ?

Hi @chendajun, and welcome!

Please provide the output of,

cat /etc/default/grub

GRUB boot loader configuration

GRUB_DEFAULT=saved
GRUB_TIMEOUT=30
GRUB_DISTRIBUTOR=“Manjaro”
GRUB_CMDLINE_LINUX_DEFAULT=“quiet splash udev.log_priority=3”
GRUB_CMDLINE_LINUX=“”

Preload both GPT and MBR modules so that they are not missed

GRUB_PRELOAD_MODULES=“part_gpt part_msdos”

Uncomment to enable booting from LUKS encrypted devices

#GRUB_ENABLE_CRYPTODISK=y

Set to ‘countdown’ or ‘menu’ to change timeout behavior,

press ESC key to display menu.

GRUB_TIMEOUT_STYLE=hidden

Uncomment to use basic console

GRUB_TERMINAL_INPUT=console

Uncomment to disable graphical terminal

#GRUB_TERMINAL_OUTPUT=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 ‘videoinfo’

GRUB_GFXMODE=auto

Uncomment to allow the kernel use the same resolution used by grub

GRUB_GFXPAYLOAD_LINUX=keep

Uncomment if you want GRUB to pass to the Linux kernel the old parameter

format “root=/dev/xxx” instead of “root=/dev/disk/by-uuid/xxx”

#GRUB_DISABLE_LINUX_UUID=true

Uncomment to disable generation of recovery mode menu entries

GRUB_DISABLE_RECOVERY=true

Uncomment and set to the desired menu colors. Used by normal and wallpaper

modes only. Entries specified as foreground/background.

GRUB_COLOR_NORMAL=“light-gray/black”
GRUB_COLOR_HIGHLIGHT=“green/black”

Uncomment one of them for the gfx desired, a image background or a gfxtheme

#GRUB_BACKGROUND=“/usr/share/grub/background.png”

Uncomment to get a beep at GRUB start

#GRUB_INIT_TUNE=“480 440 1”

Uncomment to make GRUB remember the last selection. This requires

setting ‘GRUB_DEFAULT=saved’ above.

GRUB_SAVEDEFAULT=true

Uncomment to disable submenus in boot menu

#GRUB_DISABLE_SUBMENU=y

Uncomment this option to enable os-prober execution in the grub-mkconfig command

GRUB_DISABLE_OS_PROBER=false

Uncomment to ensure that the root filesystem is mounted read-only so that

systemd-fsck can run the check automatically. We use ‘fsck’ by default, which

needs ‘rw’ as boot parameter, to avoid delay in boot-time. ‘fsck’ needs to be

removed from ‘mkinitcpio.conf’ to make ‘systemd-fsck’ work.

See also Arch-Wiki

#GRUB_ROOT_FS_RO=true
GRUB_THEME=“/usr/share/grub/themes/Manjaro-1/theme.txt”

:bangbang: Tip: :bangbang:

When posting terminal output, copy the output and paste it here, wrapped in three (3) backticks, before AND after the pasted text. Like this:

```
pasted text
```

Or three (3) tilde signs, like this:

~~~
pasted text
~~~

This will just cause it to be rendered like this:

Sed
sollicitudin dolor
eget nisl elit id
condimentum
arcu erat varius
cursus sem quis eros.

Instead of like this:

Sed sollicitudin dolor eget nisl elit id condimentum arcu erat varius cursus sem quis eros.

Alternatively, paste the text you wish to format as terminal output, select all pasted text, and click the </> button on the taskbar. This will indent the whole pasted section with one TAB, causing it to render the same way as described above.

Thereby increasing legibility thus making it easier for those trying to provide assistance.

For more information, please see:


:bangbang::bangbang: Additionally

If your language isn’t English, please prepend any and all terminal commands with LC_ALL=C. For example:

LC_ALL=C bluetoothctl

This will just cause the terminal output to be in English, making it easier to understand and debug.

1 Like
# GRUB boot loader configuration

GRUB_DEFAULT=saved
GRUB_TIMEOUT=30
GRUB_DISTRIBUTOR="Manjaro"
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash udev.log_priority=3"
GRUB_CMDLINE_LINUX=""

# Preload both GPT and MBR modules so that they are not missed
GRUB_PRELOAD_MODULES="part_gpt part_msdos"

# Uncomment to enable booting from LUKS encrypted devices
#GRUB_ENABLE_CRYPTODISK=y

# Set to 'countdown' or 'menu' to change timeout behavior,
# press ESC key to display menu.
GRUB_TIMEOUT_STYLE=hidden

# Uncomment to use basic console
GRUB_TERMINAL_INPUT=console

# Uncomment to disable graphical terminal
#GRUB_TERMINAL_OUTPUT=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 'videoinfo'
GRUB_GFXMODE=auto

# Uncomment to allow the kernel use the same resolution used by grub
GRUB_GFXPAYLOAD_LINUX=keep

# Uncomment if you want GRUB to pass to the Linux kernel the old parameter
# format "root=/dev/xxx" instead of "root=/dev/disk/by-uuid/xxx"
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
GRUB_DISABLE_RECOVERY=true

# Uncomment and set to the desired menu colors.  Used by normal and wallpaper
# modes only.  Entries specified as foreground/background.
GRUB_COLOR_NORMAL="light-gray/black"
GRUB_COLOR_HIGHLIGHT="green/black"

# Uncomment one of them for the gfx desired, a image background or a gfxtheme
#GRUB_BACKGROUND="/usr/share/grub/background.png"

# Uncomment to get a beep at GRUB start
#GRUB_INIT_TUNE="480 440 1"

# Uncomment to make GRUB remember the last selection. This requires
# setting 'GRUB_DEFAULT=saved' above.
GRUB_SAVEDEFAULT=true

# Uncomment to disable submenus in boot menu
#GRUB_DISABLE_SUBMENU=y

# Uncomment this option to enable os-prober execution in the grub-mkconfig command
GRUB_DISABLE_OS_PROBER=false

# Uncomment to ensure that the root filesystem is mounted read-only so that
# systemd-fsck can run the check automatically. We use 'fsck' by default, which
# needs 'rw' as boot parameter, to avoid delay in boot-time. 'fsck' needs to be
# removed from 'mkinitcpio.conf' to make 'systemd-fsck' work.
# See also Arch-Wiki: https://wiki.archlinux.org/index.php/Fsck#Boot_time_checking
#GRUB_ROOT_FS_RO=true
GRUB_THEME="/usr/share/grub/themes/Manjaro-1/theme.txt"

That is quite likely why you have only a back screen for 30 seconds. I had it as well.

So run the following to change it:

sudo sed -i 's/GRUB_TIMEOUT_STYLE=hidden/GRUB_TIMEOUT_STYLE=menu/1` /etc/default/grub

Then run update grub:

sudo update-grub

And reboot:

sudo reboot

(And no, I don’t know about os_prober, because mine is still on for whatever reason which I can’t remember right now. If this works, you can disable it in the config above, updated grub again and it should, theoretically, work.)

1 Like

thank you so mush! it works!

1 Like

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