2012/9/24 Lennart Poettering <[email protected]>: > On Mon, 24.09.12 11:43, Nicolas Aguirre ([email protected]) wrote: > >> Hi, >> >> Sometimes (around 1% of the time) my system doesn't start correctly. >> the init process takes 100% CPU. systemd-journal.service is not >> started correctly, and systemd tries to restart it in a loop. >> The log is here : http://pastebin.ca/2207127 >> >> >From my understanding, the problem begins with >> >> [ 12.169769] systemd[1]: Child 138 died (code=exited, status=1/FAILURE) >> [ 12.169799] systemd[1]: Child 138 belongs to systemd-journald.service >> [ 12.169830] systemd[1]: systemd-journald.service: main process >> exited, code=exited, status=1 >> >> I would like to activate journald logs to see if there is debug output >> for this error. But i have no idea how to activate journal logs. >> >> I'm running angstrom and systemd v189 with a linux kernel v3.2.19 on >> arm cortex a8 CPU. >> >> Maybe somebody will have an idea ? > > Hmm, most likely there's something in server_init() in journald.c > failing. Normally, if something fails there it should print a message to > kmsg about that. But apparently we missued something there... :-( > > Could you try to add "log_notice()" messages at various spots in > server_init() and check if you can spot where the problem is generated? > you should see the messages in kmsg. > > Lennart > > -- > Lennart Poettering - Red Hat, Inc.
Ok, I did what you said, and it appears that the problem is located in journald.c, in system_journal_open function, when it tries to read the machine-id, it can't open /etc/machine-id. My RFS is readonly , I use Ubi/Ubifs root filesystem. To fix the problem of machine-id i added a symbolic link : ln -sf /var/volatile/machine-id /etc/machine-id IIRC systemd creates this machine-id file once, but in my case it's created every time i boot because /var/volatile is tmpfs. It seems that this symbolic link is broken when journald service starts, sometimes. To fix my problem, i will create a service which will mount the fs in rw, create the /etc/machine-id and remount fs in ro if the machine-id is not found. It should work in my case because i'm using ubifs, but how to fix such problem in case of squashfs for example ? I don't have found the root cause, btw but it's a good start, thanks for your advises Regards, -- Nicolas Aguirre Mail: [email protected] Web: http://enna.geexbox.org Blog: http://dev.enlightenment.fr/~captainigloo/ _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
