Part Number: AM3358
Tool/software: Linux
Hi All -
I'm using Processor SDK 3.03.00.04.
Since the move to systemd in the SDK, I've noticed duplicate early boot log messages in the systemd journal. By this, I mean that the first journal entries for a given boot will be the expected early boot output from the kernel. Then, I'll see some later stuff (various services starting, etc...), but then at one point, later on in boot, the entire block of the first messages generated during boot will appear in the journal again.
I've traced this to when the busybox klogd service starts; it seems to be seeing the messages from early boot still in the log buffer and writing them to the journal again even though that's already been done.
To solve this issue, I first tried playing around with the settings in journald.conf (which contains settings that control how journald interacts with syslog and other log services/buffers), but was unable to find any combination of settings that got rid of the duplicate early boot entries.
I couldn't find much on this online, but one tangental page I found (not discussing duplicate early boot journal entries) mentioned that both klogd and syslog are not needed when using systemd (as long as you're using systemd's journald). After that, I decided to just try disabling both services:
systemctl disable busybox-syslog.service systemctl disable busybox-klogd.service
And that did the trick - when I booted, the duplicates were gone. This solution did not appear to cause the loss of any expected journal entries from either early boot or later, but it's hard to be sure.
So, two things:
- Since journald is enabled by default in the processor SDK distribution, should klogd and syslogd be disabled by default (or removed, though someone may wish to use them so that's probably not the way to go). Note that I'm using the GP-EVM Root FS, so I'm not sure what the state of these services is the other, default Root FS included with the SDK. Also, I realize this may have already been done in newer versions of the SDK (we'll be updating our SDK version at some point in the near future).
- Regardless of the answer to question 1., can anyone tell me if it is in fact safe for me to disable klogd and syslog? I wouldn't want to miss any kernel output that should be going to the journal, or worse, cause something to break. Seems okay so far, but I haven't run much with them disabled yet.
Thanks in advance!