450

My system is not dual-boot, I run a standard Ubuntu desktop system "on the metal" (I think running it in a VM is the same).

Pressing c while booting does not cause the GRUB menu to appear (which I believe it does for a dual-boot system).

How can I get the GRUB-menu to present itself on a single-boot system?

2
  • 41
    +1 excellent question to expose an essentially undocumented feature of Ubuntu boot process, the answer to which I only found by accident while groveling through grub.cfg. Thanks for hoisting this up to the top (Googleable) level.
    – msw
    Commented Dec 3, 2010 at 15:29
  • 8
    Credit where credit is due... This issue came up in another question of mine (buried deep in the comments). Jorge Castro suggested that it would be a good idea to present as a question it its own right... (so credit to him.... and I'm happy to bask in the reflected glow ;) I can see the value of it being a primary Q/A.
    – Peter.O
    Commented Dec 3, 2010 at 15:45

10 Answers 10

441

Menu will appear if you press and hold Shift during loading Grub, if you boot using BIOS. When your system boots using UEFI, press Esc.

For permanent change you'll need to edit your /etc/default/grub file:

Place a # symbol at the start of line GRUB_HIDDEN_TIMEOUT=0 to comment it out. If that line doesn't exist, then you can comment out this line instead: # GRUB_TIMEOUT_STYLE=hidden, and then change GRUB_TIMEOUT=0 to GRUB_TIMEOUT=5, for instance, to give the grub menu a 5 second timeout before it automatically logs you in.

Save changes and run sudo update-grub to apply changes.

Documentation: https://help.ubuntu.com/community/Grub2

13
  • 7
    @codeMonk: Oops! (I've deleted my previous comment because I was on the wrong track)... I originally misunderstood the context of "GRUB_TIMEOUT=0". The context you mean is in relation to the "permanent" display of GRUB-menu... I thought you meant in relation to the "Shift" key method... It is true that for a permanently recurring display, you need both "#GRUB_HIDDEN_TIMEOUT=0" and "GRUB_TIMEOUT=*NON-ZERO*", as described in the link in the answer ... (I've just test it both ways.)
    – Peter.O
    Commented Dec 3, 2010 at 17:24
  • 14
    Holding left shift didn't work for me :(
    – Nick
    Commented Apr 30, 2017 at 22:31
  • 24
    In Ubuntu 18.04 there is no GRUB_HIDDEN_TIMEOUT=0 line in my /etc/default/grub - instead there is GRUB_TIMEOUT_STYLE=hidden (Shift during boot never worked for me (Dell?)). Any idea what to do?
    – jena
    Commented Aug 22, 2018 at 9:10
  • 21
    @jena I found the advice at the top of /etc/default/grub helpful: i.e., to have a look at info -f grub -n 'Simple configuration'. This explains the options. Use GRUB_TIMEOUT_STYLE=menu to have the menu shown. Or press ESC if you keep the setting at hidden but want to see the menu.
    – bovender
    Commented Feb 18, 2019 at 10:18
  • 7
    Grub changes with each release, please consider adding version informatoin. The fact for example that this works only for 14.04. It sure is not relevant anymore for 18.04
    – onknows
    Commented Apr 12, 2019 at 18:18
102

I have tried both the Shift and Space keys but nothing works. Only the Esc key works for Ubuntu 14.04 and 16.04 to get Grub Menu at boot time.

12
  • 3
    same here. Only ESCAPE key worked with Ubuntu 14.04.
    – atmelino
    Commented Dec 17, 2015 at 4:52
  • 18
    The same for Ubuntu 16.04 - only Escape works. This should be mentioned in documentation (Recovery Mode)
    – matandked
    Commented Apr 23, 2016 at 13:30
  • 4
    Ubuntu 14.04 here. NOTHING works.
    – yPhil
    Commented May 16, 2016 at 23:25
  • 18
    I had to repeatedly press the ESC key, not hold it down. Let's have 6 ways to do the same thing. Linux is fun. Commented Feb 23, 2018 at 23:37
  • 3
    @jena Agree. I have several Ubuntu, but only one installed on Intel NUC wants Esc key for GRUB menu. This is problematic because if I press Esc too many times, it goes directly to GRUB CLI. Commented Aug 24, 2018 at 15:33
42

In Ubuntu 18.04, there is no GRUB_HIDDEN_TIMEOUT=0 line in /etc/default/grub - instead there is GRUB_TIMEOUT_STYLE=hidden. According to info -f grub -n 'Simple configuration' :

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.

So if you either remove or comment out the line as:

#GRUB_TIMEOUT_STYLE=hidden

and run sudo update-grub, then the menu will show by default.

18.04 + Not dual boot, boots in grub 5 seconds:

GRUB_TIMEOUT_STYLE=false

GRUB_TIMEOUT= (no value). Works fine LVM.

7
21
  • Keep hitting Shift until you see "Grub Loading Message"
  • After the message, hold the Shift down until the menu appears.
3
  • This is the nuance that helped me finally get in! Thank you! :)
    – ATSiem
    Commented Oct 24, 2014 at 3:35
  • 3
    That so does not work for me. No matter what I do to this poor SHIFT key, this Intel NUC skips the grub menu :(
    – yPhil
    Commented May 16, 2016 at 23:22
  • 2
    @yPhil Intel NUC is the freak who eats Shift. It works everywhere else. I'm lucky that Esc works for my NUC, but it didn't seem to work for you, did it? Commented Aug 24, 2018 at 15:36
16

By default, GRUB will show the menu if there is a second operating system installed. If only Ubuntu is installed, then GRUB will generally load Ubuntu without showing the menu. To reconfigure GRUB to always show a menu:

  1. Edit /etc/default/grub:

    Set GRUB_HIDDEN_TIMEOUT= (no value after the = sign).
    Set GRUB_TIMEOUT=n to show the menu for n seconds.

  2. Run update-grub to regenerate /boot/grub/grub.cfg based on the /etc/default/grub settings.

You can get GRUB to show the menu even if the default GRUB_HIDDEN_TIMEOUT=0 setting is in effect:

  • If your computer uses BIOS for booting, then hold down the Shift key while GRUB is loading to get the boot menu.
  • If your computer uses UEFI for booting, press Esc several times while GRUB is loading to get the boot menu.

Hopefully this clears up confusion as to why Shift works for some users and Esc works for others.

10

Edit /etc/default/grub (sudo -H gedit /etc/default/grub)...

change:

GRUB_TIMEOUT_STYLE=hidden

to:

GRUB_TIMEOUT_STYLE=menu

then save the file and quit the editor. Next run:

sudo update-grub 

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.

If this option is set to countdown or hidden, then, before displaying the menu, GRUB will wait for the timeout set by GRUB_TIMEOUT to expire. If ESC is pressed during that time, it will display the menu and wait for input. If a hotkey associated with a menu entry is pressed, it will boot the associated menu entry immediately. If the timeout expires before either of these happens, it will boot the default entry. In the countdown case, it will show a one-line indication of the remaining time.

8

For newer Ubuntu versions there is no GRUB_HIDDEN_TIMEOUT instead there is GRUB_TIMEOUT_STYLE which is set to hidden by default.

Open the file sudo nano /etc/default/grub Change value of GRUB_TIMEOUT_STYLE from hidden to menu and make sure GRUB_TIMEOUT is not set to 0 then run

sudo update-grub

Done!!!

3

I've heard Shift does it. But I've used Space before and it worked.

3
  • 1
    I've just now tried both Shift and Space, in two situations: In a VM, and "on the metal" ... The "Shift" worked in both situations... The "Space" failed in both situations...
    – Peter.O
    Commented Dec 3, 2010 at 15:39
  • 4
    If you can't use shift, try escape. Seems to work for me with Ubuntu 12.10.
    – user530873
    Commented Mar 25, 2013 at 23:34
  • Ubuntu 15.04. Space key works. Thanks! Commented Oct 8, 2015 at 9:11
1

Simple answer:

In the file /etc/default/grub, set GRUB_TIMEOUT=1, not 0. (Or set it to some other positive number, which is interpreted as seconds.) Then run sudo update-grub after saving the edit.

Terminal one-liner to do this:

sudo sed -i 's/^.*GRUB_TIMEOUT=.*$/GRUB_TIMEOUT=1/' /etc/default/grub && sudo update-grub
-1

For me, I found the issue was that I had left a USB stick plugged in to the computer. I suppose the computer was attempting to boot from the USB stick.

Once I had removed the USB stick, I could press shift or esc or space (depending on the version of Ubuntu you are using, I think).

You must log in to answer this question.

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