[SOLVED] Boot messages are nor journaled when /var on other

This forum is for discussion about general software issues.

[SOLVED] Boot messages are nor journaled when /var on other

Postby nbd » Tue Jul 19, 2016 10:12 pm

Greetings!

I have the /var partition mounted on an external USB hard disk with btrfs file system (in order to reduce SD card wearing). The problem is that 'journalctl -b' right after boot returns no messages at all. I don't know if the former is the cause of the latter. Later messages in the course of the session are journaled and stored OK. During boot, the messages on the screen run fast and are impossible to read, but no red colored "[FAILED]" marks are observed, only green "[OK]" ones.

In /etc/systemd/journald.conf I have a single (non-commented) line:

$this->bbcode_second_pass_code('', 'Storage=persistent')

In /etc/system.com the only entry is:

$this->bbcode_second_pass_code('', '[Manager]
LogLevel=notice')

/etc/fstab is as follows:

$this->bbcode_second_pass_code('', '/dev/mmcblk0p1 /boot vfat rw,async,noatime,auto,nouser,dev,suid,exec 0 0
LABEL="stor" /home btrfs rw,subvol=rpi/home,acl,auto,nouser,nodev,suid,exec,async 0 0
LABEL="stor" /var btrfs rw,subvol=rpi/var,acl,auto,nouser,nodev,suid,exec,async 0 0')

Both /home and /var are mounted and accessible when checked just after boot.

How to get boot messages to be journaled?

Thanks.
Albert.

EDIT:
Marked as solved.
Last edited by nbd on Wed Jul 20, 2016 7:21 pm, edited 1 time in total.
nbd
 
Posts: 14
Joined: Sun Sep 13, 2015 9:55 pm

Re: Boot messages are nor journaled when /var on other disk

Postby WarheadsSE » Wed Jul 20, 2016 12:54 pm

Are you using an initrd?
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: Boot messages are nor journaled when /var on other disk

Postby nbd » Wed Jul 20, 2016 1:02 pm

$this->bbcode_second_pass_quote('WarheadsSE', 'A')re you using an initrd?


No, no other customizations of plain vanilla configuration other than moving /home and /var to a separate partition.
nbd
 
Posts: 14
Joined: Sun Sep 13, 2015 9:55 pm

Re: Boot messages are nor journaled when /var on other disk

Postby WarheadsSE » Wed Jul 20, 2016 1:53 pm

What devices is this on? Because the vanilla configuration is different for some boards.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: Boot messages are nor journaled when /var on other disk

Postby nbd » Wed Jul 20, 2016 6:57 pm

The device is Raspberry Pi 2.

I tried to return /var back to the root partition and boot messages in this case are logged OK. Don't know how this can be explained, since the journald.conf manual reads about the "Storage=persistent" option (my case):

$this->bbcode_second_pass_quote('', 'I')f "persistent", data will be stored preferably on disk, i.e. below the /var/log/journal hierarchy (which is created if needed), with a fallback to /run/log/journal (which is created if needed), during early boot and if the disk is not writable.


I interpret this, that even if /var is not mounted yet in the early boot stage, messages should be stored anyways.
nbd
 
Posts: 14
Joined: Sun Sep 13, 2015 9:55 pm

Re: Boot messages are nor journaled when /var on other disk

Postby WarheadsSE » Wed Jul 20, 2016 6:59 pm

Yes, stored anyways, in /var, possibly prior to /var being a mount point.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: Boot messages are nor journaled when /var on other disk

Postby nbd » Wed Jul 20, 2016 7:20 pm

This makes sense. Thanks! (I thought that since the SyncIntervalSec is 5 minutes, messages should be cached. But maybe they are flushed before mounting /var.)
nbd
 
Posts: 14
Joined: Sun Sep 13, 2015 9:55 pm


Return to General

Who is online

Users browsing this forum: No registered users and 3 guests

cron