NOTE: This shows how you can adjust systemd's loglevel and get more details about the service names.
To determine systemd's loglevel you can use this command:
$ systemctl -pLogLevel show
LogLevel=debug
You can change it like this:
$ systemd-analyze set-log-level notice
$ systemctl -pLogLevel show
LogLevel=notice
The various levels are as follows:
--log-level=
Set log level. As argument this accepts a numerical log level or the
well-known syslog(3) symbolic names (lowercase): emerg, alert, crit,
err, warning, notice, info, debug.
To make it permanent between reboots you can either edit it in systemd's config file:
$ grep LogLevel /etc/systemd/system.conf
#LogLevel=info
Or set it via /etc/default/grub
file's definition for GRUB_CMDLINE_LINUX
and GRUB_CMDLINE_LINUX_DEFAULT
.
GRUB_CMDLINE_LINUX="console=tty1 console=ttyS0,115200n8 earlyprintk=ttyS0,115200 rootdelay=300 net.ifnames=0 quiet loglevel=5 rd.systemd.show_status=auto systemd.log_level=debug"
GRUB_CMDLINE_LINUX_DEFAULT="console=tty1 console=ttyS0,115200n8 earlyprintk=ttyS0,115200 rootdelay=300 net.ifnames=0 quiet loglevel=5 rd.systemd.show_status=auto systemd.log_level=debug"
Then rebuild your initramfs:
$ grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-3.10.0-693.21.1.el7.x86_64
Found initrd image: /boot/initramfs-3.10.0-693.21.1.el7.x86_64.img
Found linux image: /boot/vmlinuz-0-rescue-1ec1e304541e429e8876ba9b8942a14a
Found initrd image: /boot/initramfs-0-rescue-1ec1e304541e429e8876ba9b8942a14a.img
done
When the level is set to debug
, the messages from systemd look like this:
$ journalctl -b | less
Jul 13 12:06:44 centos7 systemd[1]: Activating default unit: default.target
Jul 13 12:06:44 centos7 systemd[1]: Trying to enqueue job initrd.target/start/isolate
Jul 13 12:06:44 centos7 systemd[1]: Installed new job local-fs.target/start as 20
Jul 13 12:06:44 centos7 systemd[1]: Installed new job systemd-udev-trigger.service/start as 18
Jul 13 12:06:44 centos7 systemd[1]: Installed new job systemd-udevd-control.socket/start as 8
Jul 13 12:06:44 centos7 systemd[1]: Installed new job remote-fs.target/start as 38
Jul 13 12:06:44 centos7 systemd[1]: Installed new job sysroot.mount/start as 31
Jul 13 12:06:44 centos7 systemd[1]: Installed new job swap.target/start as 17
Jul 13 12:06:44 centos7 systemd[1]: Installed new job kmod-static-nodes.service/start as 21
Jul 13 12:06:44 centos7 systemd[1]: Installed new job slices.target/start as 26
Jul 13 12:06:44 centos7 systemd[1]: Installed new job systemd-journald.service/start as 9
Jul 13 12:06:44 centos7 systemd[1]: Installed new job initrd-root-fs.target/start as 30
Jul 13 12:06:44 centos7 systemd[1]: Installed new job systemd-tmpfiles-setup-dev.service/start as 19
Jul 13 12:06:44 centos7 systemd[1]: Installed new job paths.target/start as 27
Jul 13 12:06:44 centos7 systemd[1]: Installed new job initrd.target/start as 1
Jul 13 12:06:44 centos7 systemd[1]: Installed new job initrd-fs.target/start as 42
...
...
Jul 13 12:06:44 centos7 systemd[1]: dracut-pre-udev.service: cgroup is empty
Jul 13 12:06:44 centos7 systemd[1]: ConditionPathIsReadWrite=/sys succeeded for systemd-udevd.service.
Jul 13 12:06:44 centos7 systemd[1]: About to execute: /usr/lib/systemd/systemd-udevd
Jul 13 12:06:44 centos7 systemd[1]: Forked /usr/lib/systemd/systemd-udevd as 226
Jul 13 12:06:44 centos7 systemd[1]: systemd-udevd.service changed dead -> start
Jul 13 12:06:44 centos7 systemd[1]: Starting udev Kernel Device Manager...
Jul 13 12:06:44 centos7 systemd[1]: Got cgroup empty notification for: /system.slice/dracut-pre-udev.service
Jul 13 12:06:44 centos7 systemd[1]: dracut-pre-udev.service: cgroup is empty
Jul 13 12:06:44 centos7 systemd[226]: Executing: /usr/lib/systemd/systemd-udevd
Jul 13 12:06:44 centos7 systemd-udevd[226]: ctrl=4 netlink=3
You can clearly see the names of the services in the above output, for eg. systemd-journald.service
.
References