Gentoo Archives: gentoo-user

From: walt <w41ter@×××××.com>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Re: journald refuses to put log files in /var/log/journal/ [REALLY SOLVED]
Date: Tue, 23 Sep 2014 21:56:18
Message-Id: lvsq91$n9g$1@ger.gmane.org
In Reply to: Re: [gentoo-user] Re: journald refuses to put log files in /var/log/journal/ [NOT SOLVED] by Mike Gilbert
1 On 09/23/2014 11:28 AM, Mike Gilbert wrote:
2 > On Tue, Sep 23, 2014 at 1:40 PM, walt <w41ter@×××××.com> wrote:
3 >> On 09/23/2014 07:46 AM, Rich Freeman wrote:
4 >>> On Tue, Sep 23, 2014 at 10:27 AM, walt <w41ter@×××××.com> wrote:
5 >>>>
6 >>>> I used systemctl to stop and restart systemd-journald, thinking I might
7 >>>> see some useful error messages. But when systemd-journal started up
8 >>>> again the journal file was back in /var/log/journal where I want it :)
9 >>>>
10 >>>> No idea why rebooting the machine didn't do the same thing.
11 >>>>
12 >>>
13 >>> Are you sure that it is solved, and that the problem won't recur on
14 >>> the next reboot?
15 >>
16 >> <sigh> After a reboot the journal file is back in /run/log/journal.
17 >>
18 >>> If it does, my next question (an educated guess, but a guess) would be
19 >>> whether you're using an initramfs,
20 >>
21 >> No, I never have.
22 >>
23 >>> I'd also look at anything
24 >>> that might be causing issues with /var/log/journal when journald is
25 >>> launched, such as that directory being on an unmounted filesystem and
26 >>> there not being some dependency that causes journald to notice.
27 >>
28 >> This particular machine has only root and swap partitions, so there's
29 >> nothing to remain unmounted during boot.
30 >>
31 >> Having reassured myself with that claim, I now spot this journal message
32 >> (which appears only on the 'broken' machine):
33 >>
34 >> Sep 23 07:40:46 a6 systemd[1]: Found ordering cycle on sysinit.target/start
35 >> Sep 23 07:40:46 a6 systemd[1]: Found dependency on local-fs.target/start
36 >> Sep 23 07:40:46 a6 systemd[1]: Found dependency on lvm.service/start
37 >> Sep 23 07:40:46 a6 systemd[1]: Found dependency on sysinit.target/start
38 >> Sep 23 07:40:46 a6 systemd[1]: Breaking ordering cycle by deleting job local-fs.target/start
39 >> Sep 23 07:40:46 a6 systemd[1]: Job local-fs.target/start deleted to break ordering cycle starting with sysinit.target/start
40 >>
41 >> I don't understand everything about that message, but it seems to imply
42 >> that systemd may think that the local filesystems are not mounted(?)
43 >>
44 >> Could this be causing my journald problem, maybe?
45 >
46 > Where is lvm.service coming from? I suspect it is causing the ordering cycle.
47
48 Great pickup, thanks Mike.
49
50 I took lvm.service from either Arch or Fedora way back when gentoo first
51 introduced systemd. For whatever reason my lvm volumes weren't being activated
52 during bootup. The lvm.service file fixed that for a long time and caused no
53 trouble until recently.
54
55 I just disabled the lvm.service and rebooted: the journal file is back in
56 /var/log/journal where it should be :)
57
58 Just as important, the lvm filesystem is properly mounted during bootup, so
59 somewhere along the line that problem got fixed independently of systemd.
60
61 Thanks again Mike, Rich, and Canek. Excellent help and much appreciated.