Updated: 28 September 2026 · Applies to: GRUB 2 on AlmaLinux and Rocky Linux 9 and 10, RHEL 9 and 10 (with grubby), Ubuntu 24.04 and 26.04, Debian 13

A wrong kernel parameter, for example a bad root= value or a driver option, can stop a server from booting. GRUB lets you change the parameters for one boot, without editing any file, so you can start the system and then fix the setting properly. The CentOS 7 steps in older guides (the linux16 line and /boot/efi/EFI/redhat/grub.cfg) no longer apply to current systems.

Before you start

  • You need to see the boot screen: the physical console, the IPMI or KVM console of a dedicated server, or the VNC console of a VPS. An SSH session cannot reach GRUB.
  • If an older kernel is still listed in the boot menu, try booting it first. That often gets a server running without edits.

Change parameters for one boot

  1. Restart the server and wait for the GRUB menu. On Ubuntu and Debian the menu may be hidden: press Esc repeatedly (UEFI) or hold Shift (BIOS) while the machine starts.
  2. Select the kernel with the arrow keys and press e.
  3. Find the line that starts with linux (on some UEFI systems linuxefi). It holds the kernel parameters, for example root=... ro crashkernel=... rhgb quiet.
  4. Move with the arrow keys and add, change or delete parameters. Useful examples: remove rhgb quiet to see boot messages; add systemd.unit=rescue.target for single-user rescue mode; add nomodeset for display problems.
  5. Press Ctrl+X (or F10) to boot. The change is not saved; it applies to this boot only.

Make the change permanent

AlmaLinux, Rocky Linux and RHEL 9 and 10 keep one file per kernel in /boot/loader/entries/. Change them with grubby:

grubby --update-kernel=ALL --args="nomodeset"        # add a parameter
grubby --update-kernel=ALL --remove-args="rhgb quiet" # remove parameters
grubby --info=ALL                                      # check the result

Kernels installed later take over the parameters of the current kernel. Only if you also run grub2-mkconfig for other reasons, update GRUB_CMDLINE_LINUX in /etc/default/grub too, then run grub2-mkconfig -o /boot/grub2/grub.cfg. On RHEL 9 and 10 this same path is correct for both BIOS and UEFI systems.

Ubuntu and Debian:

  1. Edit /etc/default/grub and change GRUB_CMDLINE_LINUX_DEFAULT (normal boots) or GRUB_CMDLINE_LINUX (all boots, including recovery).
  2. Rebuild the menu: update-grub

Check after the reboot

cat /proc/cmdline

This shows the parameters the running kernel was started with.

Common problems

  • Pressing e asks for a user name and password: a GRUB password is set. Enter it, or ask whoever set it.
  • The change is gone after a kernel update (Ubuntu, Debian): the setting was typed at boot only. Put it in /etc/default/grub and run update-grub.
  • The server still does not boot: start from rescue media and repair GRUB; see how to reinstall GRUB2 from rescue mode.

Official documentation: Configuring kernel command-line parameters (Red Hat) and GNU GRUB manual.

Ucartz services for this topic

Was this answer helpful? 0 Users Found This Useful (1 Votes)