There are 1000 things that can go wrong ultimately leading to server crash/freeze. Some of the most common reason are : network problems, system overload, configuration errors, hardware issues, out of disk space etc.
When things go wrong we restart server in recover mode. Sometimes by default on reboot, grubs menu shows up with no timeout. This can prevent you from automatically rebooting your servers (as grub will infinitely wait for a user input).
You certainly in most of the cases want to avoid such situation. This can easily be done in a few steps.
Open the file
/etc/default/grub with an editor and add the variable
GRUB_RECORDFAIL_TIMEOUT as following:
GRUB_RECORDFAIL_TIMEOUT = N
where N = desired timeout in seconds. This will make the grub wait for N secs and then continue with default choice.
In case you do not want any timeout at all, set it to -1.
GRUB_RECORDFAIL_TIMEOUT = -1
If you want to completely disable the menu (even for failed startup), set it to 0
GRUB_RECORDFAIL_TIMEOUT = 0
Now save the file and update grub by:
This will apply your changes to the grub as desired.