From: Luca Adrian L Date: Mon, 3 May 2021 15:08:25 +0000 (+0200) Subject: Document the need to do journalctl --flush for persistent logging (#19481) X-Git-Tag: v249-rc1~310 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=19d25fdec120c679e34eb4f3276bedcdfd6f5bed;p=thirdparty%2Fsystemd.git Document the need to do journalctl --flush for persistent logging (#19481) Document the need to do journalctl --flush for persistent logging. (fixes #19480) Co-authored-by: Luca Lindhorst --- diff --git a/man/journald.conf.xml b/man/journald.conf.xml index 86137a951de..06583d5ed3f 100644 --- a/man/journald.conf.xml +++ b/man/journald.conf.xml @@ -78,6 +78,11 @@ the kernel log buffer, or a syslog socket will still work). Defaults to auto in the default journal namespace, and persistent in all others. + Note that journald will initially use volatile storage, until a call to + journalctl --flush (or sending SIGUSR1 to journald) will cause + it to switch to persistent logging (under the conditions mentioned above). This is done automatically + on boot via systemd-journal-flush.service. + Note that when this option is changed to volatile, existing persistent data is not removed. In the other direction, journalctl1 with diff --git a/man/systemd-journald.service.xml b/man/systemd-journald.service.xml index 875393b4081..b66e6ea8ebc 100644 --- a/man/systemd-journald.service.xml +++ b/man/systemd-journald.service.xml @@ -80,6 +80,11 @@ journald.conf5 to configure where log data is placed, independently of the existence of /var/log/journal/. + Note that journald will initially use volatile storage, until a call to + journalctl --flush (or sending SIGUSR1 to journald) will cause + it to switch to persistent logging (under the conditions mentioned above). This is done automatically + on boot via systemd-journal-flush.service. + On systems where /var/log/journal/ does not exist yet but where persistent logging is desired (and the default journald.conf is used), it is sufficient to create the directory, and ensure it has the correct access modes and ownership: