• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

How to debug systemd boot process in CentOS/RHEL 7 and 8

by admin

Question: How to debug/find, changes or failing commands during the boot process?

1. 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

2. On the line with “linux” remove following entries if present to get more details at boot time.

splash=silent quiet showopts

3. Then add following entries to get step by step.

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

4. Once the changes are done, save them with “CTRL+x” and booting shall continue from here with verbose systemd debugging.

Note: These are temporary changes to the booting and will not affect the next booting.

Filed Under: CentOS/RHEL, CentOS/RHEL 7, CentOS/RHEL 8, Linux

Some more articles you might also be interested in …

  1. Unable To Extend LVM File System with Associated Snapshot in CentOS/RHEL
  2. How to Create a New /boot Partition in CentOS / RHEL
  3. How to calculate recommended value of vm.min_free_kbytes Kernel Tuning Parameter
  4. How to Connect Remote Host Using the ssh Command
  5. pvdisplay Command Examples in Linux
  6. lvdisplay error: “Failed to create directory /var/lock/lvm. File-based locking initilisation failed.”
  7. Echo Command with Practical Examples
  8. How to map /dev/sdX and /dev/mapper/mpathY device from the /dev/dm-Z device
  9. RHEL / CentOS : How to shrink LVM volume
  10. How to disable auto completion (tab completion) in bash shell

You May Also Like

Primary Sidebar

Recent Posts

  • JavaFX ComboBox: Set a value to the combo box
  • Nginx load balancing
  • nginx 504 gateway time-out
  • Images preview with ngx_http_image_filter_module

© 2022 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright