Good morning,
I’d like to submit a feature request, but I’m not sure to what component this would apply.
Yesterday, I copied my root and boot filesystems to a new drive. I used rsync -aX to perform the copies, so I thought I had taken care of SELinux contexts. When I tried booting from the drive, the console would display a lot of failures from systemd-journald.service and other systemd components. These error messages instructed me to use “systemctl status ” to see the reason for the failure. The kernel would then panic and hang.
Because of the panic & hang, I couldn’t run systemctl status to see actual error messages. Whatever the error was, it prevented mounting root in rw mode, so I couldn’t boot from alternate media to read the logs.
I tried adding boot_delay=100 to the kernel parameters, but that hung the system after a single line. I tried taking a video of the console while booting, but I didn’t see anything other than systemd components failing to start. No reason why given, just the fact they failed.
I spent several hours googling for things like “systemd.journald failed on boot”, but didn’t get anything that helped. I finally just assumed that I was dealing with an SELinux problem and did the 'touch /.autorelabel" trick while booted from alternate media.
This has happened to me twice in the past few years. I don’t like trying random changes to see if they fixed the problem. If I’d seen a console message that said “SELinux context error”, I would have tried autorelabel immediately. All I saw was “Failed to start systemd-”, however.
The request I’d like to make is to add one or both of these features:
-
As soon as possible in the boot sequence, check the SELinux context for all required files. If any of them fail, display the names of the files that failed and why. Then, either pause the boot for a few seconds or just stop booting, either of which will allow users to take a picture or read the messages.
-
If any error occurs, don’t just print “Failed, see systemctl status”. Write the log message to the console and pause or stop the boot.
Basically, anything that actually lets folks read the error messages when journald doesn’t start or root can’t be [re]mounted rw.
I know one can hook up a serial console, but how many non-enterprise folks have computers with serial ports these days, much less a serial console handy?
Thanks,
Matt