Ivan Tomica

Remove EFI grub timeout

Ever since I’ve set up EFI boot on my machine using grub I had this issue with timeout option not wanting to go away.

Digging into the issue I first looked at /boot/grub/grub.cfg where I found this piece of code:


if [ $grub_platform = efi ]; then
  set timeout=30
  if [ x$feature_timeout_style = xy ] ; then
    set timeout_style=menu
  fi
fi

“This is weird” I said to myself, where does that come from? It is defined in /etc/grub.d/00_header file

if [ "$recordfail_broken" = 1 ]; then
  cat << EOF
if [ \$grub_platform = efi ]; then
  set timeout=${GRUB_RECORDFAIL_TIMEOUT:-30}
  if [ x\$feature_timeout_style = xy ] ; then
    set timeout_style=menu
  fi
fi
EOF
fi

So this states if GRUB_RECORDFAIL_TIMEOUT is not defined or is null default of 30 should be set.

According to that I’ve added

GRUB_RECORDFAIL_TIMEOUT=10

to my /etc/default/grub, which should give me 10 second timeout (instead of 30). I don’t set it to null or 1 since I want to have a bit of wiggle-room if things go south during the boot process.

Don’t forget to run:

sudo update-grub
Tagged in:, , ,

0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *