Linux

Where Is the GRUB Config File?

GRUB keeps boot menu defaults in /etc/default/grub with generated config under /boot on Linux. Files and update routine.

Last updated

GRUB splits human settings from generated output. Defaults live in a small file under /etc/default while the real menu builds into /boot on every update. OS prober appends other systems during generation.

That split decides every edit. Change defaults, regenerate, reboot. Direct edits to generated files vanish silently at the next kernel install, which surprises first time tweakers.

Where GRUB stores this, by platform

Linux
/etc/default/grub

Human edited defaults for timeout, entries and kernel flags. Regenerate the boot menu after every change with the distro updater. Custom stanzas go in the custom include file.

Linux
/boot/grub/grub.cfg

Generated boot menu plus themes and fonts. Rebuilt on every kernel update, so hand edits here never survive. Treat this tree as output rather than config.

Frequently asked questions

How do I change boot defaults?

Edit /etc/default/grub for defaults like timeout, default entry and kernel flags, then regenerate the real config with the distro updater command. Never hand edit the generated file since the next update overwrites it. Keep a live USB nearby when touching boot entries.

Where is the boot menu?

In the generated config under /boot, rebuilt from defaults plus OS prober results on every update. Custom stanzas belong in the custom include file rather than the generated tree. Back up defaults before experimenting.

Notice an outdated path? Let us know.