I think that I found a simpler resolution.
Modify the following lines in the file /etc/default/grub :
GRUB_HIDDEN_TIMEOUT=0.0
GRUB_TIMEOUT=0.0
Of course we finally run an update-grub.
It works on my PC.
You need to make:
GRUB_HIDDEN_TIMEOUT=5
GRUB_TIMEOUT=0
Then, when you switch the computer on, pres ESC
to enter to the boot menu, otherwise, the computer will boot in the default selection.
For sake of simplicity, you can change those values easily with Grub Customizer
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
In the tab General, click on advanced settings, then, select active the following keys and update the values to:
GRUB_HIDDEN_TIMEOUT = 5
GRUB_TIMEOUT = 0
Optional, to display a counter showing the remaining seconds while you can press ESC
, set:
GRUB_HIDDEN_TIMEOUT_QUIET = false
Best Answer
Check out the extremely detailed and well-written Wiki entry for Grub2. The setting
GRUB_HIDDEN_TIMEOUT
should be what you are looking for. But pay attention to the instructions on how to change settings.