Question: How to debug/find, changes or failing commands during boot process?
During boot process, when seeing grub boot menu press “e” for edit the grub, then scroll down until you see boot entry:
echo "Loading Linux... linux16 /vmlinuz-XXX root=XXXro crashkernel=auto rd.lvm.lv=rhel/root rd.lvm.lv=rhel/swap rhgb quiet LANG=en_US.UTF-8
On the line with “linux” remove the following entries if present to get more details at boot time.
splash=silent quiet showopts
Then add following entries to get step by step debug logs.
plymouth.enable=0 systemd.confirm_spawn=true systemd.debug-shell=1 systemd.log_level=debug systemd.unit=multi-user.target console=tty1
Here,
plymouth.enable=0 will disable plymouth bootsplash.
systemd.confirm_spawn=true asks for confirmation when spawning processes like interactive boot.
systemd.debug-shell=1 enables a root shell on console 9 (reachable via F9).
systemd.log_level=debug enables debug logging.
systemd.unit=multi-user.target avoids switch to console 7 for output and input stays at console 1.
console=tty1 avoids switch of input/ouput to console 9 where bash will get attached.
With CTRL+x booting with the given changes, these changes are not permanent.