From 24d007a0a8a77a6b75c6c7a403fc8d107875ebdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Sat, 9 May 2015 16:20:51 -0500 Subject: [PATCH] man: document forwarding to syslog better https://bugzilla.redhat.com/show_bug.cgi?id=1147651 Cherry-picked from: 589532d0 Resolves: #1177336 --- man/journald.conf.xml | 70 +++++++++++++++++++++++++++---------------- 1 file changed, 44 insertions(+), 26 deletions(-) diff --git a/man/journald.conf.xml b/man/journald.conf.xml index 85146b0d8..abfe3130d 100644 --- a/man/journald.conf.xml +++ b/man/journald.conf.xml @@ -97,7 +97,7 @@ needed, so that its existence controls where log data goes. none turns off all storage, all log data received will be dropped. Forwarding to other targets, such as - the console, the kernel log buffer or a syslog daemon will + the console, the kernel log buffer, or a syslog socket will still work however. Defaults to auto. @@ -220,27 +220,19 @@ journald will stop using more space, but it will not be removing existing files to go reduce footprint either. - SystemMaxFileSize= - and - RuntimeMaxFileSize= - control how large individual journal - files may grow at maximum. This - influences the granularity in which - disk space is made available through - rotation, i.e. deletion of historic - data. Defaults to one eighth of the - values configured with + SystemMaxFileSize= and + RuntimeMaxFileSize= control how large + individual journal files may grow at maximum. This influences + the granularity in which disk space is made available through + rotation, i.e. deletion of historic data. Defaults to one + eighth of the values configured with SystemMaxUse= and - RuntimeMaxUse=, so - that usually seven rotated journal - files are kept as history. Specify - values in bytes or use K, M, G, T, P, - E as units for the specified sizes - (equal to 1024, 1024²,... bytes). - Note that size limits are enforced - synchronously when journal files are - extended, and no explicit rotation - step triggered by time is + RuntimeMaxUse=, so that usually seven + rotated journal files are kept as history. Specify values in + bytes or use K, M, G, T, P, E as units for the specified sizes + (equal to 1024, 1024²,... bytes). Note that size limits are + enforced synchronously when journal files are extended, and no + explicit rotation step triggered by time is needed. @@ -308,13 +300,13 @@ daemon, to the kernel log buffer (kmsg), to the system console, or sent as wall messages to all logged-in users. These options take boolean arguments. If forwarding to syslog - is enabled but no syslog daemon is running, the respective - option has no effect. By default, only forwarding wall is - enabled. These settings may be overridden at boot time with - the kernel command line options + is enabled but nothing reads messages from the socket, + forwarding to syslog has no effect. By default, only + forwarding to wall is enabled. These settings may be + overridden at boot time with the kernel command line options systemd.journald.forward_to_syslog=, systemd.journald.forward_to_kmsg=, - systemd.journald.forward_to_console= and + systemd.journald.forward_to_console=, and systemd.journald.forward_to_wall=. When forwarding to the console, the TTY to log to can be changed with TTYPath=, described @@ -365,6 +357,32 @@ + + Forwarding to traditional syslog daemons + + + Journal events can be transfered to a different logging daemon + in two different ways. In the first method, messages are + immediately forwarded to a socket + (/run/systemd/journal/syslog), where the + traditional syslog daemon can read them. This method is + controlled by ForwardToSyslog= option. In a + second method, a syslog daemon behaves like a normal journal + client, and reads messages from the journal files, similarly to + journalctl1. + In this method, messages do not have to be read immediately, + which allows a logging daemon which is only started late in boot + to access all messages since the start of the system. In + addition, full structured meta-data is available to it. This + method of course is available only if the messages are stored in + a journal file at all. So it will work if + Storage=none is set. It should be noted that + usualy the second method is used by syslog + daemons, so the Storage= option, and not the + ForwardToSyslog= option, is relevant for them. + + + See Also