4

this is my first time posting here. I tried my best to work this problem out on my own but it didn't work out.

I did't want a timeout on my GRUB boot menu, I wanted it to remain indefinitely until I make a choice. So I edited my GRUB customization file as follows:

sudo nano /etc/default/grub

GRUB_DEFAULT='Windows Boot Manager (on /dev/sda1)'
# GRUB_HIDDEN_TIMEOUT=0
# GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=-1
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""

and then I ran

sudo update-grub

Then tried to hibernate and wake up and the timeout was still 30 seconds.
I wanted to know how the timeouts in my grub.cfg file look like so I ran this command:

cat /boot/grub/grub.cfg | grep timeout

  set timeout=30
  if [ x$feature_timeout_style = xy ] ; then
    set timeout_style=menu
    set timeout=-1
  # Fallback normal timeout code in case the timeout_style feature is
    set timeout=-1

set timeout_style=menu
if [ "${timeout}" = 0 ]; then
  set timeout=10

It seems to me like the default timeout is still 30.. I suspect it's a hibernation thing but I have to reboot to make sure if the countdown exists only when I hibernate...


EDIT: It definitely is a hibernation thing. When I reboot, the boot menu remains indefinitely, but when I hibernate, it counts down from 30.


EDIT2: Nevermind. Sometimes this issue doesn't happen on reboot or hibernation, sometimes it happens with both, sometimes it's either. I have no idea how to troubleshoot the cause with such an unpredictable behaviour..


EDIT3: Here are my hibernation configs:

sudo cat /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla

[Re-enable hibernate by default for login1]
  Identity=unix-user:*
  Action=org.freedesktop.login1.hibernate
  ResultActive=yes

[Re-enable hibernate for multiple users by default in logind]
  Identity=unix-user:*
  Action=org.freedesktop.login1.hibernate-multiple-sessions
  ResultActive=yes
3
  • 1
    I use the same timeout GRUB_TIMEOUT=-1 and also I un-commented the line # GRUB_HIDDEN_TIMEOUT_QUIET=true. Grub menu always waits for input. I never used hibernation though, so try it out and see if it is better then
    – mook765
    May 17, 2018 at 18:09
  • Voting to close as unreproducible. See OP's EDIT2. May 21, 2018 at 2:46
  • @WinEunuuchs2Unix it could be a configuration I'm overlooking or something of such. I think I've posted enough troubleshooting info to reproduce this. It's a 50/50 chance so after a couple of hibernations or reboots it will be encountered.
    – Moth
    May 21, 2018 at 10:57

1 Answer 1

2

Look at the documentation, in the terminal with info grub or online at gnu.org

‘GRUB_TIMEOUT_STYLE’

    If this option is unset or set to ‘menu’, then GRUB will display the menu and then wait for the timeout set by ‘GRUB_TIMEOUT’ to expire before booting the default entry. Pressing a key interrupts the timeout. 

'GRUB_TIMEOUT'
     Boot the default entry this many seconds after the menu is
     displayed, unless a key is pressed.  The default is '5'.  Set to
     '0' to boot immediately without displaying the menu, or to '-1' to
     wait indefinitely.

     If 'GRUB_TIMEOUT_STYLE' is set to 'countdown' or 'hidden', the
     timeout is instead counted before the menu is displayed.

So you should set GRUB_TIMEOUT to 0. And to get the menu being displayed until an entry is chosen aka indefenitvly you must set GRUB_TIMEOUT_STYLE to menu.

Is GRUB_DEFAULT correct ? You want to boot into windows by default ?

1
  • I want my grub menu to show indefinitely. Using GRUB_TIMEOUT = 0 will not make this happen. It will instead take me directly to the default OS. Which is indeed Windows because I boot on that more (For reasons involving MatLab, AutoCAD, SolidWorks, etc..)
    – Moth
    May 20, 2018 at 13:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .