Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just re-installed Ubuntu 12.10 after having various issues, it was just time for a re-format and re-install.


The install went the smoothest that it has ever gone. Except that on my installed system I don't have the /etc/default/grub file that I need to configure grub. In my curiosity I ran sudo update-grub, and it ran seamlessly despite the file missing.

I will add that I am installing grub-efi, and loading it via rEFInd on boot.

Attempted Repairs

I've also re-downloaded Ubuntu, re-formatted and re-installed, verified files and md5 sums on the new installation media, and yet they're still gone. I've also tried the Ubuntu boot repair tool, which completed successfully but didn't actually restore the /etc/default/grub file.


How can I get the needed /etc/default/grub configuration file?

Thanks for your help in advance.

share|improve this question
What is your question? – guntbert Feb 16 '13 at 22:02
I'm wondering what I need to do to get the needed /etc/default/grub file. Sorry for being unclear. – John Feb 17 '13 at 2:08
up vote 0 down vote accepted

After installing tuxonice to enable hibernation, I noticed that one of the outputs was that it couldn't find /etc/default/grub and it kindly created one for me.

However I would still love to know what the actual way of re-creating this file is, as it seems to be a persistent issue. I say this because I've tried re-installing 12.10, and was still left with this issue.

share|improve this answer
according to apt-file this file isn't part of any package. So it probably gets created by other means. You could attempt to apt-get --reinstall install ... your chosen grub package. – 0xC0000022L Feb 17 '13 at 21:23

Did not find how to regenerate it but here's mine:

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#   info -f grub -n 'Simple configuration'

GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`

# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)

# Uncomment to disable graphical terminal (grub-pc only)

# 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'

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux

# Uncomment to disable generation of recovery mode menu entries

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.