mirror of
https://github.com/systemd/systemd.git
synced 2024-12-22 17:35:35 +03:00
man: add a note about "archived" journal files and when files can be copied
Issue #6673 requests advice on backup strategy. But the right backup strategy depends on many factors, too many to describe in a man page. So let's just provide some general information which files are mutable and that it is always safe to use/copy files. Closes #6673.
This commit is contained in:
parent
2230a2908b
commit
4bb890bc04
@ -261,9 +261,7 @@ systemd-tmpfiles --create --prefix /var/log/journal</programlisting>
|
||||
<varlistentry>
|
||||
<term><filename>/etc/systemd/journald.conf</filename></term>
|
||||
|
||||
<listitem><para>Configure
|
||||
<command>systemd-journald</command>
|
||||
behavior. See
|
||||
<listitem><para>Configure <command>systemd-journald</command> behavior. See
|
||||
<citerefentry><refentrytitle>journald.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
@ -274,8 +272,7 @@ systemd-tmpfiles --create --prefix /var/log/journal</programlisting>
|
||||
<term><filename>/var/log/journal/<replaceable>machine-id</replaceable>/*.journal</filename></term>
|
||||
<term><filename>/var/log/journal/<replaceable>machine-id</replaceable>/*.journal~</filename></term>
|
||||
|
||||
<listitem><para><command>systemd-journald</command> writes
|
||||
entries to files in
|
||||
<listitem><para><command>systemd-journald</command> writes entries to files in
|
||||
<filename>/run/log/journal/<replaceable>machine-id</replaceable>/</filename>
|
||||
or
|
||||
<filename>/var/log/journal/<replaceable>machine-id</replaceable>/</filename>
|
||||
@ -287,7 +284,19 @@ systemd-tmpfiles --create --prefix /var/log/journal</programlisting>
|
||||
<filename>/var/log/journal</filename> is not available, or
|
||||
when <option>Storage=volatile</option> is set in the
|
||||
<citerefentry><refentrytitle>journald.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>
|
||||
configuration file.</para></listitem>
|
||||
configuration file.</para>
|
||||
|
||||
<para>When <filename>systemd-journald</filename> ceases writing to a journal file,
|
||||
it will be renamed to <literal><replaceable>original-name</replaceable>@<replaceable>suffix.journal</replaceable></literal>
|
||||
(or <literal><replaceable>original-name</replaceable>@<replaceable>suffix.journal~</replaceable></literal>).
|
||||
Such files are "archived" and will not be written to any more.</para>
|
||||
|
||||
<para>In general, it is safe to read or copy any journal file (active or archived).
|
||||
<citerefentry><refentrytitle>journalctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
|
||||
and the functions in the
|
||||
<citerefentry><refentrytitle>sd-journal</refentrytitle><manvolnum>3</manvolnum></citerefentry>
|
||||
library should be able to read all entries that have been fully written.</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
|
Loading…
Reference in New Issue
Block a user