有馬総一郎のブログ

(彼氏の事情)

2025年10月02日 18:42:15 JST - 1 minute read - Linux

`Check GRUB_DISABLE_OS_PROBER documentation entry`と警告が出るので調べてみた。

あるとき、以下のメセージが表示されるようになった。

Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...

どうも、以前は、GRUB(ブートローダー)が、設定を更新する度にos-proberが自動実行されて、他のインストールされているOSを検出して、ブートメニューに追加してくれていたが、今はセキュリティ上の懸念からデフォルトでは無効となったらしい。

なので、もしマルチブートにしている場合は、以下のように設定を変更して、os-proberを無効としているのを有効としなければならない。

/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=""
GRUB_CMDLINE_LINUX=""
+GRUB_DISABLE_OS_PROBER=false

すると、以下のメッセージのように他のOSを検出しますよ、とこれはこれでセキュリティ上の懸念から警告が出される。

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.
Adding boot menu entry for UEFI Firmware Settings ...

また、trueと明示的に無効化した場合も警告メッセージは変わらない。どっちにしろ警告が出る。 マルチブートにしてなければ追加・編集不要だが、これまで動きが変わったんだと認識しておきたい。