Setting Grub Options The Right Way
Grub is the default boot loader for Ubuntu and it comes with a huge set of options that you might be inclined to tweek when ever you choose to debug a problem during bootup. The simple quickfire way to make Grub do what you want is to edit it just before the boot process occurs (Hit ‘E’ key when the options are listed), this provides for easy access but the changes are non permanent. The next time you reboot the options will have switched to the default.
To make permanent changes to Grub you need to edit the “/etc/default/grub” file and rebuild your Grub. Open the /etc/default/grub file in any editor(in sudo mode), I prefer to use nano or vi, the file will look something like this:
# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
GRUB_DEFAULT=0
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""
# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_LINUX_RECOVERY="true"
# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
Now you can edit the parts that you need and save the file. For Eg. I needed to remove Splash and Quiet as options from grub so that I could see where exactly my boot sequence failed. I edited the entry GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash” and removed ‘quiet splash’ from within the quotes.
After editing the file you will need to update your grub with the settings. For this execute the command:
sudo update-grub
Grub will automatically get updated with the changes and the next time you reboot the settings will be set by default.