Package: rsyslog
Version: 8.2510.0-2
Severity: minor
Tags: patch

>From "/usr/share/doc/debian/bug-reporting.txt.gz":

  Don't file bugs upstream

   If you file a bug in Debian, don't send a copy to the upstream software
   maintainers yourself, as it is possible that the bug exists only in
   Debian. If necessary, the maintainer of the package will forward the
   bug upstream.

-.-

  I do not send reports upstream if I have to get an account there.
The Debian maintainers have one already.

-.-

   * What led up to the situation?

     Checking for defects with a new version

test-[g|n]roff -mandoc -t -K utf8 -rF0 -rHY=0 -rCHECKSTYLE=0 -ww -z < "man page"

  [Use 

grep -n -e ' $' -e '\\~$' -e ' \\f.$' -e ' \\"' <file>

  to find (most) trailing spaces.]

  ["test-groff" is a script in the repository for "groff"; is not shipped]
(local copy and "troff" slightly changed by me).

  [The fate of "test-nroff" was decided in groff bug #55941.]

   * What was the outcome of this action?

Output from "test-groff  -mandoc -t -K utf8 -rF0 -rHY=0 -rCHECKSTYLE=0 -ww -z ":

troff:<stdin>:59: warning: trailing space in the line
troff:<stdin>:132: warning: trailing space in the line
troff:<stdin>:139: warning: trailing space in the line
troff:<stdin>:140: warning: trailing space in the line
troff:<stdin>:145: warning: trailing space in the line
troff:<stdin>:146: warning: trailing space in the line
troff:<stdin>:151: warning: trailing space in the line
troff:<stdin>:157: warning: trailing space in the line
troff:<stdin>:158: warning: trailing space in the line
troff:<stdin>:237: warning: trailing space in the line
troff:<stdin>:238: warning: trailing space in the line
troff:<stdin>:242: warning: trailing space in the line
troff:<stdin>:270: warning: trailing space in the line
troff:<stdin>:271: warning: trailing space in the line
troff:<stdin>:272: warning: trailing space in the line
troff:<stdin>:295: warning: trailing space in the line
troff:<stdin>:327: warning: trailing space in the line
troff:<stdin>:329: warning: trailing space in the line
troff:<stdin>:334: warning: trailing space in the line
troff:<stdin>:341: warning: trailing space in the line
troff:<stdin>:343: warning: trailing space in the line
troff:<stdin>:349: warning: trailing space in the line
troff:<stdin>:350: warning: trailing space in the line
troff:<stdin>:351: warning: trailing space in the line
troff:<stdin>:352: warning: trailing space in the line
troff:<stdin>:364: warning: trailing space in the line
troff:<stdin>:366: warning: trailing space in the line
troff:<stdin>:370: warning: trailing space in the line
troff:<stdin>:378: warning: trailing space in the line
troff:<stdin>:393: warning: trailing space in the line
troff:<stdin>:394: warning: trailing space in the line
troff:<stdin>:395: warning: trailing space in the line
troff:<stdin>:399: warning: trailing space in the line
troff:<stdin>:400: warning: trailing space in the line
troff:<stdin>:402: warning: trailing space in the line
troff:<stdin>:403: warning: trailing space in the line
troff:<stdin>:404: warning: trailing space in the line
troff:<stdin>:405: warning: trailing space in the line
troff:<stdin>:422: warning: trailing space in the line
troff:<stdin>:441: warning: trailing space in the line
troff:<stdin>:442: warning: trailing space in the line
troff:<stdin>:443: warning: trailing space in the line
troff:<stdin>:444: warning: trailing space in the line
troff:<stdin>:447: warning: trailing space in the line
troff:<stdin>:454: warning: trailing space in the line
troff:<stdin>:455: warning: trailing space in the line
troff:<stdin>:456: warning: trailing space in the line
troff:<stdin>:459: warning: trailing space in the line
troff:<stdin>:460: warning: trailing space in the line
troff:<stdin>:476: warning: trailing space in the line
troff:<stdin>:483: warning: trailing space in the line
troff:<stdin>:487: warning: trailing space in the line
troff:<stdin>:488: warning: trailing space in the line
troff:<stdin>:489: warning: trailing space in the line
troff:<stdin>:497: warning: trailing space in the line
troff:<stdin>:498: warning: trailing space in the line
troff:<stdin>:499: warning: trailing space in the line
troff:<stdin>:504: warning: trailing space in the line
troff:<stdin>:505: warning: trailing space in the line
troff:<stdin>:506: warning: trailing space in the line
troff:<stdin>:512: warning: trailing space in the line
troff:<stdin>:514: warning: trailing space in the line
troff:<stdin>:516: warning: trailing space in the line
troff:<stdin>:517: warning: trailing space in the line
troff:<stdin>:518: warning: trailing space in the line
troff:<stdin>:519: warning: trailing space in the line
troff:<stdin>:523: warning: trailing space in the line
troff:<stdin>:524: warning: trailing space in the line
troff:<stdin>:525: warning: trailing space in the line
troff:<stdin>:526: warning: trailing space in the line
troff:<stdin>:527: warning: trailing space in the line
troff:<stdin>:528: warning: trailing space in the line
troff:<stdin>:529: warning: trailing space in the line
troff:<stdin>:532: warning: trailing space in the line
troff:<stdin>:535: warning: trailing space in the line
troff:<stdin>:580: warning: trailing space in the line
troff:<stdin>:590: warning: trailing space in the line
troff:<stdin>:592: warning: trailing space in the line
troff:<stdin>:601: warning: trailing space in the line
troff:<stdin>:602: warning: trailing space in the line
troff:<stdin>:603: warning: trailing space in the line
troff:<stdin>:604: warning: trailing space in the line
troff:<stdin>:607: warning: trailing space in the line
troff:<stdin>:608: warning: trailing space in the line
troff:<stdin>:616: warning: trailing space in the line
troff:<stdin>:617: warning: trailing space in the line
troff:<stdin>:618: warning: trailing space in the line
troff:<stdin>:622: warning: trailing space in the line
troff:<stdin>:629: warning: trailing space in the line
troff:<stdin>:644: warning: trailing space in the line
troff:<stdin>:651: warning: trailing space in the line
troff:<stdin>:718: warning: trailing space in the line
troff:<stdin>:722: warning: trailing space in the line
troff:<stdin>:723: warning: trailing space in the line
troff:<stdin>:724: warning: trailing space in the line
troff:<stdin>:725: warning: trailing space in the line
troff:<stdin>:726: warning: trailing space in the line
troff:<stdin>:727: warning: trailing space in the line
troff:<stdin>:730: warning: trailing space in the line
troff:<stdin>:732: warning: trailing space in the line
troff:<stdin>:733: warning: trailing space in the line
troff:<stdin>:734: warning: trailing space in the line
troff:<stdin>:736: warning: trailing space in the line
troff:<stdin>:737: warning: trailing space in the line
troff:<stdin>:738: warning: trailing space in the line
troff:<stdin>:739: warning: trailing space in the line
troff:<stdin>:742: warning: trailing space in the line
troff:<stdin>:743: warning: trailing space in the line
troff:<stdin>:744: warning: trailing space in the line
troff:<stdin>:745: warning: trailing space in the line
troff:<stdin>:746: warning: trailing space in the line
troff:<stdin>:747: warning: trailing space in the line
troff:<stdin>:748: warning: trailing space in the line
troff:<stdin>:749: warning: trailing space in the line
troff:<stdin>:750: warning: trailing space in the line
troff:<stdin>:751: warning: trailing space in the line
troff:<stdin>:754: warning: trailing space in the line
troff:<stdin>:755: warning: trailing space in the line

   * What outcome did you expect instead?

     No output (no warnings).

-.-

  General remarks and further material, if a diff-file exist, are in the
attachments.


-- System Information:
Debian Release: forky/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 6.16.12+deb14+1-amd64 (SMP w/2 CPU threads; PREEMPT)
Locale: LANG=is_IS.iso88591, LC_CTYPE=is_IS.iso88591 (charmap=ISO-8859-1), 
LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: sysvinit (via /sbin/init)

Versions of packages rsyslog depends on:
ii  libc6         2.41-12
ii  libestr0      0.1.11-2
ii  libfastjson4  1.2304.0-2
ii  liblognorm5   2.0.7-1
ii  libsystemd0   258.1-1
ii  libuuid1      2.41.2-1
ii  libzstd1      1.5.7+dfsg-2
ii  zlib1g        1:1.3.dfsg+really1.3.1-1+b1

Versions of packages rsyslog recommends:
ii  logrotate  3.22.0-1

Versions of packages rsyslog suggests:
pn  rsyslog-clickhouse                <none>
ii  rsyslog-doc                       8.2510.0-2
pn  rsyslog-docker                    <none>
pn  rsyslog-elasticsearch             <none>
pn  rsyslog-gssapi                    <none>
pn  rsyslog-hiredis                   <none>
pn  rsyslog-kafka                     <none>
pn  rsyslog-kubernetes                <none>
pn  rsyslog-mongodb                   <none>
pn  rsyslog-mysql                     <none>
pn  rsyslog-openssl | rsyslog-gnutls  <none>
pn  rsyslog-pgsql                     <none>
pn  rsyslog-relp                      <none>
pn  rsyslog-snmp                      <none>

-- no debconf information
Input file is rsyslog.conf.5

Output from "mandoc -T lint  rsyslog.conf.5": (shortened list)

      1 ERROR: skipping end of block that is not open: RE
    124 STYLE: input text line longer than 80 bytes: 
    123 STYLE: whitespace at end of input line
      1 WARNING: skipping paragraph macro: br before sp


Find most trailing spaces with:
grep -n -e ' $' -e ' \\f.$' -e ' \\"' <man page>

-.-.

Output from
test-nroff -mandoc -t -ww -z rsyslog.conf.5: (shortened list)

    118 line(s) with a trailing space


Find most trailing spaces with:
grep -n -e ' $' -e ' \\f.$' -e ' \\"' <man page>

-.-.

Remove space characters (whitespace) at the end of lines.
Use "git apply ... --whitespace=fix" to fix extra space issues, or use
global configuration "core.whitespace".

Number of lines affected is

124

-.-.

Reduce space between words.

rsyslog.conf.5:4:.\" This file is part of the rsyslog  package, an enhanced 
system log daemon.

-.-.

Wrong distance (not two spaces) between sentences in the input file.

  Separate the sentences and subordinate clauses; each begins on a new
line.  See man-pages(7) ("Conventions for source file layout") and
"info groff" ("Input Conventions").

  The best procedure is to always start a new sentence on a new line,
at least, if you are typing on a computer.

Remember coding: Only one command ("sentence") on each (logical) line.

E-mail: Easier to quote exactly the relevant lines.

Generally: Easier to edit the sentence.

Patches: Less unaffected text.

Search for two adjacent words is easier, when they belong to the same line,
and the same phrase.

  The amount of space between sentences in the output can then be
controlled with the ".ss" request.

Mark a final abbreviation point as such by suffixing it with "\&".

Some sentences (etc.) do not begin on a new line.

Split (sometimes) lines after a punctuation mark; before a conjunction.

  Lines with only one (or two) space(s) between sentences could be split,
so latter sentences begin on a new line.

Use

#!/usr/bin/sh

sed -e '/^\./n' \
-e 's/\([[:alpha:]]\)\.  */\1.\n/g' $1

to split lines after a sentence period.
Check result with the difference between the formatted outputs.
See also the attachment "general.bugs"

[List of affected lines removed.]

-.-.

Split lines longer than 80 characters (fill completly
an A4 sized page line on a terminal)
into two or more lines.
Appropriate break points are the end of a sentence and a subordinate
clause; after punctuation marks.
Add "\:" to split the string for the output, "\<newline>" in the source.  

[List of affected lines removed.]

Longest line is number 780 with 245 characters
replace control characters (ASCII value 127 and values less then 32) with an 
escape sequence. The sequence is "#<charval>" where charval is the 3-digit 
decimal value of the control character. For example, a tabulator would be 
replaced by "#009".

-.-.

The name of a man page is typeset in bold and the section in roman
(see man-pages(7)).

275:command before rsyslogd(8) is started.

-.-.

Put a parenthetical sentence, phrase on a separate line,
if not part of a code.
See man-pages(7), item "semantic newline".

[List of affected lines removed.]

-.-

FSF office address update.  See
https://lists.gnu.org/archive/html/bug-gnulib/2024-09/msg00004.html

18:.\" Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.

-.-.

Only one space character is after a possible end of sentence
(after a punctuation, that can end a sentence).

[List of affected lines removed.]

-.-.

Space character after a macro call.

515:.B MUST 

-.-.

Add "\&" after an ellipsis, when it does not end a sentence.

234:An easier approach is probably to do if ... then based matching in script.

-.-.

Output from "test-groff  -mandoc -t -K utf8 -rF0 -rHY=0 -rCHECKSTYLE=0 -ww -z ":

troff:<stdin>:59: warning: trailing space in the line
troff:<stdin>:132: warning: trailing space in the line
troff:<stdin>:139: warning: trailing space in the line
troff:<stdin>:140: warning: trailing space in the line
troff:<stdin>:145: warning: trailing space in the line
troff:<stdin>:146: warning: trailing space in the line
troff:<stdin>:151: warning: trailing space in the line
troff:<stdin>:157: warning: trailing space in the line
troff:<stdin>:158: warning: trailing space in the line
troff:<stdin>:237: warning: trailing space in the line
troff:<stdin>:238: warning: trailing space in the line
troff:<stdin>:242: warning: trailing space in the line
troff:<stdin>:270: warning: trailing space in the line
troff:<stdin>:271: warning: trailing space in the line
troff:<stdin>:272: warning: trailing space in the line
troff:<stdin>:295: warning: trailing space in the line
troff:<stdin>:327: warning: trailing space in the line
troff:<stdin>:329: warning: trailing space in the line
troff:<stdin>:334: warning: trailing space in the line
troff:<stdin>:341: warning: trailing space in the line
troff:<stdin>:343: warning: trailing space in the line
troff:<stdin>:349: warning: trailing space in the line
troff:<stdin>:350: warning: trailing space in the line
troff:<stdin>:351: warning: trailing space in the line
troff:<stdin>:352: warning: trailing space in the line
troff:<stdin>:364: warning: trailing space in the line
troff:<stdin>:366: warning: trailing space in the line
troff:<stdin>:370: warning: trailing space in the line
troff:<stdin>:378: warning: trailing space in the line
troff:<stdin>:393: warning: trailing space in the line
troff:<stdin>:394: warning: trailing space in the line
troff:<stdin>:395: warning: trailing space in the line
troff:<stdin>:399: warning: trailing space in the line
troff:<stdin>:400: warning: trailing space in the line
troff:<stdin>:402: warning: trailing space in the line
troff:<stdin>:403: warning: trailing space in the line
troff:<stdin>:404: warning: trailing space in the line
troff:<stdin>:405: warning: trailing space in the line
troff:<stdin>:422: warning: trailing space in the line
troff:<stdin>:441: warning: trailing space in the line
troff:<stdin>:442: warning: trailing space in the line
troff:<stdin>:443: warning: trailing space in the line
troff:<stdin>:444: warning: trailing space in the line
troff:<stdin>:447: warning: trailing space in the line
troff:<stdin>:454: warning: trailing space in the line
troff:<stdin>:455: warning: trailing space in the line
troff:<stdin>:456: warning: trailing space in the line
troff:<stdin>:459: warning: trailing space in the line
troff:<stdin>:460: warning: trailing space in the line
troff:<stdin>:476: warning: trailing space in the line
troff:<stdin>:483: warning: trailing space in the line
troff:<stdin>:487: warning: trailing space in the line
troff:<stdin>:488: warning: trailing space in the line
troff:<stdin>:489: warning: trailing space in the line
troff:<stdin>:497: warning: trailing space in the line
troff:<stdin>:498: warning: trailing space in the line
troff:<stdin>:499: warning: trailing space in the line
troff:<stdin>:504: warning: trailing space in the line
troff:<stdin>:505: warning: trailing space in the line
troff:<stdin>:506: warning: trailing space in the line
troff:<stdin>:512: warning: trailing space in the line
troff:<stdin>:514: warning: trailing space in the line
troff:<stdin>:516: warning: trailing space in the line
troff:<stdin>:517: warning: trailing space in the line
troff:<stdin>:518: warning: trailing space in the line
troff:<stdin>:519: warning: trailing space in the line
troff:<stdin>:523: warning: trailing space in the line
troff:<stdin>:524: warning: trailing space in the line
troff:<stdin>:525: warning: trailing space in the line
troff:<stdin>:526: warning: trailing space in the line
troff:<stdin>:527: warning: trailing space in the line
troff:<stdin>:528: warning: trailing space in the line
troff:<stdin>:529: warning: trailing space in the line
troff:<stdin>:532: warning: trailing space in the line
troff:<stdin>:535: warning: trailing space in the line
troff:<stdin>:580: warning: trailing space in the line
troff:<stdin>:590: warning: trailing space in the line
troff:<stdin>:592: warning: trailing space in the line
troff:<stdin>:601: warning: trailing space in the line
troff:<stdin>:602: warning: trailing space in the line
troff:<stdin>:603: warning: trailing space in the line
troff:<stdin>:604: warning: trailing space in the line
troff:<stdin>:607: warning: trailing space in the line
troff:<stdin>:608: warning: trailing space in the line
troff:<stdin>:616: warning: trailing space in the line
troff:<stdin>:617: warning: trailing space in the line
troff:<stdin>:618: warning: trailing space in the line
troff:<stdin>:622: warning: trailing space in the line
troff:<stdin>:629: warning: trailing space in the line
troff:<stdin>:644: warning: trailing space in the line
troff:<stdin>:651: warning: trailing space in the line
troff:<stdin>:718: warning: trailing space in the line
troff:<stdin>:722: warning: trailing space in the line
troff:<stdin>:723: warning: trailing space in the line
troff:<stdin>:724: warning: trailing space in the line
troff:<stdin>:725: warning: trailing space in the line
troff:<stdin>:726: warning: trailing space in the line
troff:<stdin>:727: warning: trailing space in the line
troff:<stdin>:730: warning: trailing space in the line
troff:<stdin>:732: warning: trailing space in the line
troff:<stdin>:733: warning: trailing space in the line
troff:<stdin>:734: warning: trailing space in the line
troff:<stdin>:736: warning: trailing space in the line
troff:<stdin>:737: warning: trailing space in the line
troff:<stdin>:738: warning: trailing space in the line
troff:<stdin>:739: warning: trailing space in the line
troff:<stdin>:742: warning: trailing space in the line
troff:<stdin>:743: warning: trailing space in the line
troff:<stdin>:744: warning: trailing space in the line
troff:<stdin>:745: warning: trailing space in the line
troff:<stdin>:746: warning: trailing space in the line
troff:<stdin>:747: warning: trailing space in the line
troff:<stdin>:748: warning: trailing space in the line
troff:<stdin>:749: warning: trailing space in the line
troff:<stdin>:750: warning: trailing space in the line
troff:<stdin>:751: warning: trailing space in the line
troff:<stdin>:754: warning: trailing space in the line
troff:<stdin>:755: warning: trailing space in the line

-.-

Generally:

Split (sometimes) lines after a punctuation mark; before a conjunction.

-.-
--- rsyslog.conf.5      2025-10-27 21:51:12.214886974 +0000
+++ rsyslog.conf.5.new  2025-10-27 22:20:59.430145527 +0000
@@ -1,18 +1,18 @@
 .\" rsyslog.conf - rsyslogd(8) configuration file
 .\" Copyright 2003-2008 Rainer Gerhards and Adiscon GmbH.
-.\" 
+.\"
 .\" This file is part of the rsyslog  package, an enhanced system log daemon.
-.\" 
+.\"
 .\" This program is free software; you can redistribute it and/or modify
 .\" it under the terms of the GNU General Public License as published by
 .\" the Free Software Foundation; either version 2 of the License, or
 .\" (at your option) any later version.
-.\" 
+.\"
 .\" This program is distributed in the hope that it will be useful,
 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 .\" GNU General Public License for more details.
-.\" 
+.\"
 .\" You should have received a copy of the GNU General Public License
 .\" along with this program; if not, write to the Free Software
 .\" Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
@@ -56,7 +56,7 @@ Output module for GSS-enabled syslog
 Output module for MySQL
 .TP
 .I omrelp
-Output module for the reliable RELP protocol (prevents message loss). 
+Output module for the reliable RELP protocol (prevents message loss).
 For details, see below at imrelp and the HTML documentation.
 It can be used like this:
 .IP
@@ -129,33 +129,33 @@ are doing.
 
 .SH BASIC STRUCTURE
 
-Lines starting with a hash mark ('#') and empty lines are ignored. 
+Lines starting with a hash mark ('#') and empty lines are ignored.
 Rsyslog.conf should contain following sections (sorted by recommended order in 
file):
 
 .TP
 Global directives
 Global directives set some global properties of whole rsyslog daemon, for 
example size of main
 message queue ($MainMessageQueueSize), loading external modules ($ModLoad) and 
so on.
-All global directives need to be specified on a line by their own and must 
start with 
-a dollar-sign. The complete list of global directives can be found in HTML 
documentation in doc 
+All global directives need to be specified on a line by their own and must 
start with
+a dollar-sign. The complete list of global directives can be found in HTML 
documentation in doc
 directory or online on web pages.
 
 .TP
 Templates
-Templates allow you to specify format of the logged message. They are also 
used for dynamic 
-file name generation. They have to be defined before they are used in rules. 
For more info 
+Templates allow you to specify format of the logged message. They are also 
used for dynamic
+file name generation. They have to be defined before they are used in rules. 
For more info
 about templates see TEMPLATES section of this manpage.
 
 .TP
 Output channels
-Output channels provide an umbrella for any type of output that the user might 
want. 
+Output channels provide an umbrella for any type of output that the user might 
want.
 They have to be defined before they are used in rules. For more info about 
output channels
 see OUTPUT CHANNELS section of this manpage.
 
 .TP
 Rules (selector + action)
-Every rule line consists of two fields, a selector field and an action field. 
These 
-two fields are separated by one or more spaces or tabs. The selector field 
specifies 
+Every rule line consists of two fields, a selector field and an action field. 
These
+two fields are separated by one or more spaces or tabs. The selector field 
specifies
 a pattern of facilities and priorities belonging to the specified action.
 
 .SH SELECTORS
@@ -231,15 +231,15 @@ BSD syslog selector:
 
 *.debug;local6.!=info;local6.!=notice;local6.!=warn
 
-An easier approach is probably to do if ... then based matching in script.
+An easier approach is probably to do if ...\& then based matching in script.
 
 .SH ACTIONS
-The action field of a rule describes what to do with the message. In general, 
message content 
-is written to a kind of "logfile". But also other actions might be done, like 
writing to a 
+The action field of a rule describes what to do with the message. In general, 
message content
+is written to a kind of "logfile". But also other actions might be done, like 
writing to a
 database table or forwarding to another host.
 
 .SS Regular file
-Typically messages are logged to real files. The file has to be specified with 
full pathname, 
+Typically messages are logged to real files. The file has to be specified with 
full pathname,
 beginning with a slash ('/').
 
 .B Example:
@@ -267,12 +267,14 @@ file path with a minus sign ("\-").
 .SS Named pipes
 This version of
 .BR rsyslogd (8)
-has support for logging output to named pipes (fifos). A fifo or 
-named pipe can be used as a destination for log messages by prepending a pipe 
symbol ('|') 
-to the name of the file. This is handy for debugging. Note that the fifo must 
be created with 
+has support for logging output to named pipes (fifos). A fifo or
+named pipe can be used as a destination for log messages by prepending a pipe 
symbol ('|')
+to the name of the file. This is handy for debugging. Note that the fifo must 
be created with
 the
 .BR mkfifo (1)
-command before rsyslogd(8) is started.
+command before
+.BR rsyslogd (8)
+is started.
 
 .SS Terminal and console
 If the file you specified is a tty, special tty-handling is done, same with 
/dev/console.
@@ -292,7 +294,7 @@ string ":omrelp:" in front of the hostna
 *.* @192.168.0.1
 .RE
 .sp
-In the example above, messages are forwarded via UDP to the machine 
192.168.0.1, the destination 
+In the example above, messages are forwarded via UDP to the machine 
192.168.0.1, the destination
 port defaults to 514. Due to the nature of UDP, you will probably lose some 
messages in transit.
 If you expect high traffic volume, you can expect to lose a quite noticeable 
number of messages
 (the higher the traffic, the more likely and severe is message loss).
@@ -324,32 +326,32 @@ forwarding. For full details, please see
 
 .SS List of users
 Usually critical messages are also directed to ``root'' on that machine. You
-can specify a list 
+can specify a list
 of users that shall get the message by simply writing ":omusrmsg:" followed
-by the login name. You may specify more than one 
+by the login name. You may specify more than one
 user by separating them with commas (','). If they're logged in they
 get the message (for example: ":omusrmsg:root,user1,user2").
 
 .SS Everyone logged on
-Emergency messages often go to all users currently online to notify them that 
something strange 
+Emergency messages often go to all users currently online to notify them that 
something strange
 is happening with the system. To specify this
 .BR wall (1)-feature
 use an ":omusrmsg:*".
 
 .SS Database table
 This allows logging of the message to a database table.
-By default, a MonitorWare-compatible schema is required for this to work. You 
can 
+By default, a MonitorWare-compatible schema is required for this to work. You 
can
 create that schema with the createDB.SQL file that came with the rsyslog 
package. You can also
-use any other schema of your liking \(en you just need to define a proper 
template and assign this 
+use any other schema of your liking \(en you just need to define a proper 
template and assign this
 template to the action.
 
 See the HTML documentation for further details on database logging.
 
 .SS Discard
-If the discard action is carried out, the received message is immediately 
discarded. Discard 
-can be highly effective if you want to filter out some annoying messages that 
otherwise would 
-fill your log files. To do that, place the discard actions early in your log 
files. 
-This often plays well with property-based filters, giving you great freedom in 
specifying 
+If the discard action is carried out, the received message is immediately 
discarded. Discard
+can be highly effective if you want to filter out some annoying messages that 
otherwise would
+fill your log files. To do that, place the discard actions early in your log 
files.
+This often plays well with property-based filters, giving you great freedom in 
specifying
 what you do not want.
 
 Discard is just the single 'stop' command with no further parameters.
@@ -361,13 +363,13 @@ Discard is just the single 'stop' comman
 
 
 .SS Output channel
-Binds an output channel definition (see there for details) to this action. 
Output channel actions 
+Binds an output channel definition (see there for details) to this action. 
Output channel actions
 must start with a $-sign, e.g.\& if you would like to bind your output channel 
definition "mychannel"
-to the action, use "$mychannel". Output channels support template definitions 
like all other 
+to the action, use "$mychannel". Output channels support template definitions 
like all other
 actions.
 
 .SS Shell execute
-This executes a program in a subshell. The program is passed the 
template-generated message as the 
+This executes a program in a subshell. The program is passed the 
template-generated message as the
 only command line parameter. Rsyslog waits until the program terminates and 
only then continues to run.
 
 .B Example:
@@ -375,7 +377,7 @@ only command line parameter. Rsyslog wai
 ^program-to-execute;template
 .RE
 
-The program-to-execute can be any valid executable. It receives the template 
string as a single parameter 
+The program-to-execute can be any valid executable. It receives the template 
string as a single parameter
 (argv[1]).
 
 .SH FILTER CONDITIONS
@@ -386,23 +388,22 @@ Rsyslog offers three different types "fi
    * property-based filters
 .sp 0
    * expression-based filters
-.RE
 
 .SS Selectors
 .B Selectors are the traditional way of filtering syslog messages.
-They have been kept in rsyslog with their original syntax, because it is 
well-known, highly 
-effective and also needed for compatibility with stock syslogd configuration 
files. If you just 
-need to filter based on priority and facility, you should do this with 
selector lines. They are 
+They have been kept in rsyslog with their original syntax, because it is 
well-known, highly
+effective and also needed for compatibility with stock syslogd configuration 
files. If you just
+need to filter based on priority and facility, you should do this with 
selector lines. They are
 not second-class citizens in rsyslog and offer the best performance for this 
job.
 
 .SS Property-Based Filters
-Property-based filters are unique to rsyslogd. They allow one to filter on any 
property, like HOSTNAME, 
-syslogtag and msg. 
+Property-based filters are unique to rsyslogd. They allow one to filter on any 
property, like HOSTNAME,
+syslogtag and msg.
 
-A property-based filter must start with a colon in column 0. This tells 
rsyslogd that it is the new 
-filter type. The colon must be followed by the property name, a comma, the 
name of the compare 
-operation to carry out, another comma and then the value to compare against. 
This value must be quoted. 
-There can be spaces and tabs between the commas. Property names and compare 
operations are 
+A property-based filter must start with a colon in column 0. This tells 
rsyslogd that it is the new
+filter type. The colon must be followed by the property name, a comma, the 
name of the compare
+operation to carry out, another comma and then the value to compare against. 
This value must be quoted.
+There can be spaces and tabs between the commas. Property names and compare 
operations are
 case-sensitive, so "msg" works, while "MSG" is an invalid property name. In 
brief, the syntax is as follows:
 .sp
 .RS
@@ -411,7 +412,6 @@ case-sensitive, so "msg" works, while "M
 
 The following compare-operations are currently supported:
 .sp
-.RS
 .B contains
 .RS
 Checks if the string provided in value is contained in the property
@@ -419,7 +419,7 @@ Checks if the string provided in value i
 .sp
 .B isequal
 .RS
-Compares the "value" string provided and the property contents. These two 
values must be exactly equal to match. 
+Compares the "value" string provided and the property contents. These two 
values must be exactly equal to match.
 .RE
 .sp
 .B startswith
@@ -438,26 +438,26 @@ See the HTML documentation for this feat
 
 .SH TEMPLATES
 
-Every output in rsyslog uses templates \(en this holds true for files, user 
-messages and so on. Templates compatible with the stock syslogd 
-formats are hardcoded into rsyslogd. If no template is specified, we use 
-one of these hardcoded templates. Search for "template_" in syslogd.c and 
+Every output in rsyslog uses templates \(en this holds true for files, user
+messages and so on. Templates compatible with the stock syslogd
+formats are hardcoded into rsyslogd. If no template is specified, we use
+one of these hardcoded templates. Search for "template_" in syslogd.c and
 you will find the hardcoded ones.
 
-A template consists of a template directive, a name, the actual template text 
+A template consists of a template directive, a name, the actual template text
 and optional options. A sample is:
 
 .RS
 .B $template MyTemplateName,"\e\e7Text %property% some more 
text\e\en",<options>
 .RE
 
-The "$template" is the template directive. It tells rsyslog that this line 
-contains a template. The backslash is an escape character. For example, \e7 
rings the 
-bell (this is an ASCII value), \en is a new line. The set in rsyslog is a bit 
restricted 
+The "$template" is the template directive. It tells rsyslog that this line
+contains a template. The backslash is an escape character. For example, \e7 
rings the
+bell (this is an ASCII value), \en is a new line. The set in rsyslog is a bit 
restricted
 currently.
 
-All text in the template is used literally, except for things within percent 
-signs. These are properties and allow you access to the contents of the syslog 
+All text in the template is used literally, except for things within percent
+signs. These are properties and allow you access to the contents of the syslog
 message. Properties are accessed via the property replacer and it can for 
example
 pick a substring or do date-specific formatting. More on this is the PROPERTY 
REPLACER
 section of this manpage.
@@ -473,20 +473,20 @@ $template TraditionalFormat,"%timegenera
 Properties can be accessed by the property replacer (see there for details).
 
 .B Please note that templates can also by used to generate selector lines with 
dynamic file names.
-For example, if you would like to split syslog messages from different hosts 
+For example, if you would like to split syslog messages from different hosts
 to different files (one per host), you can define the following template:
 
 .RS
 .B $template DynFile,"/var/log/system-%HOSTNAME%.log"
 .RE
-    
-This template can then be used when defining an output selector line. It will 
+
+This template can then be used when defining an output selector line. It will
 result in something like "/var/log/system-localhost.log"
 
 .SS Template options
-The <options> part is optional. It carries options influencing the template as 
whole. 
-See details below. Be sure NOT to mistake template options with property 
options \(en the 
-later ones are processed by the property replacer and apply to a SINGLE 
property, only 
+The <options> part is optional. It carries options influencing the template as 
whole.
+See details below. Be sure NOT to mistake template options with property 
options \(en the
+later ones are processed by the property replacer and apply to a SINGLE 
property, only
 (and not the whole template).
 
 Template options are case-insensitive. Currently defined are:
@@ -494,45 +494,45 @@ Template options are case-insensitive. C
 .RS
 .TP
 sql
-format the string suitable for a SQL statement in MySQL format. This will 
replace single 
-quotes ("'") and the backslash character by their backslash-escaped 
counterpart 
-("\'" and "\e") inside each field. Please note that in MySQL configuration, 
the NO_BACKSLASH_ESCAPES 
+format the string suitable for a SQL statement in MySQL format. This will 
replace single
+quotes ("'") and the backslash character by their backslash-escaped counterpart
+("\'" and "\e") inside each field. Please note that in MySQL configuration, 
the NO_BACKSLASH_ESCAPES
 mode must be turned off for this format to work (this is the default).
 
 .TP
 stdsql
-format the string suitable for a SQL statement that is to be sent to a 
standards-compliant 
-sql server. This will replace single quotes ("'") by two single quotes ("''") 
inside each field. 
-You must use stdsql together with MySQL if in MySQL configuration the 
NO_BACKSLASH_ESCAPES 
+format the string suitable for a SQL statement that is to be sent to a 
standards-compliant
+sql server. This will replace single quotes ("'") by two single quotes ("''") 
inside each field.
+You must use stdsql together with MySQL if in MySQL configuration the 
NO_BACKSLASH_ESCAPES
 is turned on.
 .RE
 
 Either the
 .B sql
-or 
+or
 .B stdsql
-option 
-.B MUST 
-be specified when a template is used for writing to a database, 
-otherwise injection might occur. Please note that due to the unfortunate fact 
-that several vendors have violated the sql standard and introduced their own 
-escape methods, it is impossible to have a single option doing all the work.  
+option
+.B MUST
+be specified when a template is used for writing to a database,
+otherwise injection might occur. Please note that due to the unfortunate fact
+that several vendors have violated the sql standard and introduced their own
+escape methods, it is impossible to have a single option doing all the work.
 So you yourself must make sure you are using the right format.
 .B If you choose the wrong one, you are still vulnerable to sql injection.
 
-Please note that the database writer *checks* that the sql option is present 
-in the template. If it is not present, the write database action is disabled. 
-This is to guard you against accidental forgetting it and then becoming 
-vulnerable to SQL injection. The sql option can also be useful with files \(en 
-especially if you want to import them into a database on another machine for 
-performance reasons. However, do NOT use it if you do not have a real need for 
-it \(en among others, it takes some toll on the processing time. Not much, but 
on 
+Please note that the database writer *checks* that the sql option is present
+in the template. If it is not present, the write database action is disabled.
+This is to guard you against accidental forgetting it and then becoming
+vulnerable to SQL injection. The sql option can also be useful with files \(en
+especially if you want to import them into a database on another machine for
+performance reasons. However, do NOT use it if you do not have a real need for
+it \(en among others, it takes some toll on the processing time. Not much, but 
on
 a really busy system you might notice it ;)
 
-The default template for the write to database action has the sql option set. 
+The default template for the write to database action has the sql option set.
 
 .SS Template examples
-Please note that the samples are split across multiple lines. A template MUST 
+Please note that the samples are split across multiple lines. A template MUST
 NOT actually be split across multiple lines.
 
 A template that resembles traditional syslogd file output:
@@ -577,7 +577,7 @@ $template MySQLInsert,"insert iut, messa
 ('%iut%', '%msg:::UPPERCASE%', '%timegenerated:::date-mysql%')
 into systemevents\er\en", SQL
 
-NOTE 1: This template is embedded into core application under name 
+NOTE 1: This template is embedded into core application under name
 .B StdDBFmt
 , so you don't need to define it.
 .sp
@@ -587,9 +587,9 @@ NOTE 2: You have to have MySQL module in
 
 .SH OUTPUT CHANNELS
 
-Output Channels are a new concept first introduced in rsyslog 0.9.0. As of 
this writing, 
+Output Channels are a new concept first introduced in rsyslog 0.9.0. As of 
this writing,
 it is most likely that they will be replaced by something different in the 
future.
-So if you use them, be prepared to change you configuration file syntax when 
you upgrade 
+So if you use them, be prepared to change you configuration file syntax when 
you upgrade
 to a later release.
 
 Output channels are defined via an $outchannel directive. It's syntax is as 
follows:
@@ -598,14 +598,14 @@ Output channels are defined via an $outc
 .B $outchannel name,file-name,max-size,action-on-max-size
 .RE
 
-name is the name of the output channel (not the file), file-name is the file 
name to be 
-written to, max-size the maximum allowed size and action-on-max-size a command 
to be issued 
-when the max size is reached. This command always has exactly one parameter. 
The binary is 
-that part of action-on-max-size before the first space, its parameter is 
everything behind 
+name is the name of the output channel (not the file), file-name is the file 
name to be
+written to, max-size the maximum allowed size and action-on-max-size a command 
to be issued
+when the max size is reached. This command always has exactly one parameter. 
The binary is
+that part of action-on-max-size before the first space, its parameter is 
everything behind
 that space.
 
-Keep in mind that $outchannel just defines a channel with "name". It does not 
activate it. 
-To do so, you must use a selector line (see below). That selector line 
includes the channel 
+Keep in mind that $outchannel just defines a channel with "name". It does not 
activate it.
+To do so, you must use a selector line (see below). That selector line 
includes the channel
 name plus ":omfile:$" in front of it. A sample might be:
 .sp
 .RS
@@ -613,20 +613,20 @@ name plus ":omfile:$" in front of it. A
 .RE
 
 .SH PROPERTY REPLACER
-The property replacer is a core component in rsyslogd's output system. A 
syslog message has 
-a number of well-defined properties (see below). Each of this properties can 
be accessed and 
-manipulated by the property replacer. With it, it is easy to use only part of 
a property value 
+The property replacer is a core component in rsyslogd's output system. A 
syslog message has
+a number of well-defined properties (see below). Each of this properties can 
be accessed and
+manipulated by the property replacer. With it, it is easy to use only part of 
a property value
 or manipulate the value, e.g.\& by converting all characters to lower case.
 
 .SS Accessing Properties
-Syslog message properties are used inside templates. They are accessed by 
putting them between 
+Syslog message properties are used inside templates. They are accessed by 
putting them between
 percent signs. Properties can be modified by the property replacer. The full 
syntax is as follows:
 .sp
 .RS
 .B %propname:fromChar:toChar:options%
 .RE
 
-propname is the name of the property to access. 
+propname is the name of the property to access.
 .B It is case-sensitive.
 
 .SS Available Properties
@@ -641,14 +641,14 @@ the message exactly as it was received f
 hostname from the message
 .TP
 .B FROMHOST
-hostname of the system the message was received from (in a relay chain, this 
is the system immediately 
+hostname of the system the message was received from (in a relay chain, this 
is the system immediately
 in front of us and not necessarily the original sender)
 .TP
 .B syslogtag
 TAG from the message
 .TP
 .B programname
-the "static" part of the tag, as defined by BSD syslogd. For example, when TAG 
is "named[12345]", 
+the "static" part of the tag, as defined by BSD syslogd. For example, when TAG 
is "named[12345]",
 programname is "named".
 .TP
 .B PRI
@@ -715,44 +715,44 @@ The current hour in military (24 hour) t
 The current minute (2-digit)
 
 .P
-Properties starting with a $-sign are so-called system properties. These do 
NOT stem from the 
+Properties starting with a $-sign are so-called system properties. These do 
NOT stem from the
 message but are rather internally-generated.
 
 .SS Character Positions
-FromChar and toChar are used to build substrings. They specify the offset 
within the string that 
-should be copied. Offset counting starts at 1, so if you need to obtain the 
first 2 characters of 
-the message text, you can use this syntax: "%msg:1:2%". If you do not wish to 
specify from and to, 
-but you want to specify options, you still need to include the colons. For 
example, if you would 
-like to convert the full message text to lower case, use "%msg:::lowercase%". 
If you would like to 
-extract from a position until the end of the string, you can place a 
dollar-sign ("$") in toChar 
+FromChar and toChar are used to build substrings. They specify the offset 
within the string that
+should be copied. Offset counting starts at 1, so if you need to obtain the 
first 2 characters of
+the message text, you can use this syntax: "%msg:1:2%". If you do not wish to 
specify from and to,
+but you want to specify options, you still need to include the colons. For 
example, if you would
+like to convert the full message text to lower case, use "%msg:::lowercase%". 
If you would like to
+extract from a position until the end of the string, you can place a 
dollar-sign ("$") in toChar
 (e.g.\& %msg:10:$%, which will extract from position 10 to the end of the 
string).
 
-There is also support for 
+There is also support for
 .B regular expressions.
-To use them, you need to place a "R" into FromChar. 
-This tells rsyslog that a regular expression instead of position-based 
extraction is desired. The 
-actual regular expression 
+To use them, you need to place a "R" into FromChar.
+This tells rsyslog that a regular expression instead of position-based 
extraction is desired. The
+actual regular expression
 .B must
-then be provided in toChar. The regular expression must be followed 
-by the string "\-\-end". It denotes the end of the regular expression and will 
not become part of it. 
-If you are using regular expressions, the property replacer will return the 
part of the property text 
-that matches the regular expression. An example for a property replacer 
sequence with a regular 
+then be provided in toChar. The regular expression must be followed
+by the string "\-\-end". It denotes the end of the regular expression and will 
not become part of it.
+If you are using regular expressions, the property replacer will return the 
part of the property text
+that matches the regular expression. An example for a property replacer 
sequence with a regular
 expression is: "%msg:R:.*Sev:. \e(.*\e) \e[.*\-\-end%"
 
-Also, extraction can be done based on so-called "fields". To do so, place a 
"F" into FromChar. A field 
-in its current definition is anything that is delimited by a delimiter 
character. The delimiter by 
-default is TAB (US-ASCII value 9). However, if can be changed to any other 
US-ASCII character by 
-specifying a comma and the decimal US-ASCII value of the delimiter immediately 
after the "F". For example, 
-to use comma (",") as a delimiter, use this field specifier: "F,44".  If your 
syslog data is delimited, 
-this is a quicker way to extract than via regular expressions (actually, a 
*much* quicker way). Field 
-counting starts at 1. Field zero is accepted, but will always lead to a "field 
not found" error. The same 
-happens if a field number higher than the number of fields in the property is 
requested. The field number 
-must be placed in the "ToChar" parameter. An example where the 3rd field 
(delimited by TAB) from the msg 
-property is extracted is as follows: "%msg:F:3%". The same example with 
semicolon as delimiter is 
+Also, extraction can be done based on so-called "fields". To do so, place a 
"F" into FromChar. A field
+in its current definition is anything that is delimited by a delimiter 
character. The delimiter by
+default is TAB (US-ASCII value 9). However, if can be changed to any other 
US-ASCII character by
+specifying a comma and the decimal US-ASCII value of the delimiter immediately 
after the "F". For example,
+to use comma (",") as a delimiter, use this field specifier: "F,44".  If your 
syslog data is delimited,
+this is a quicker way to extract than via regular expressions (actually, a 
*much* quicker way). Field
+counting starts at 1. Field zero is accepted, but will always lead to a "field 
not found" error. The same
+happens if a field number higher than the number of fields in the property is 
requested. The field number
+must be placed in the "ToChar" parameter. An example where the 3rd field 
(delimited by TAB) from the msg
+property is extracted is as follows: "%msg:F:3%". The same example with 
semicolon as delimiter is
 "%msg:F,59:3%".
 
-Please note that the special characters "F" and "R" are case-sensitive. Only 
upper case works, lower case 
-will return an error. There are no white spaces permitted inside the sequence 
(that will lead to error 
+Please note that the special characters "F" and "R" are case-sensitive. Only 
upper case works, lower case
+will return an error. There are no white spaces permitted inside the sequence 
(that will lead to error
 messages and will NOT provide the intended result).
 
 .SS Property Options
  Any program (person), that produces man pages, should check the output
for defects by using (both groff and nroff)

[gn]roff -mandoc -t -ww -b -z -K utf8 <man page>

  To find trailing space use

grep -n -e ' $' -e ' \\f.$' -e ' \\"' <man page>

  The same goes for man pages that are used as an input.

-.-

  For a style guide use

  mandoc -T lint

-.-

  For general input conventions consult the man page "nroff(7)" (item
"Input conventions") or the Texinfo manual about the same item.

-.-

  Any "autogenerator" should check its products with the above mentioned
'groff', 'mandoc', and additionally with 'nroff ...'.

  It should also check its input files for too long (> 80) lines.

  This is just a simple quality control measure.

  The "autogenerator" may have to be corrected to get a better man page,
the source file may, and any additional file may.

  Common defects:

  Not removing trailing spaces (in in- and output).
  The reason for these trailing spaces should be found and eliminated.

  "git" has a "tool" to point out whitespace,
see for example "git-apply(1)" and git-config(1)")

  Not beginning each input sentence on a new line.
Line length and patch size should thus be reduced.

  The script "reportbug" uses 'quoted-printable' encoding when a line is
longer than 1024 characters in an 'ascii' file.

  See man-pages(7), item "semantic newline".

-.-

The difference between the formatted output of the original
and patched file can be seen with:

  nroff -mandoc <file1> > <out1>
  nroff -mandoc <file2> > <out2>
  diff -d -u <out1> <out2>

and for groff, using

\"printf '%s\n%s\n' '.kern 0' '.ss 12 0' | groff -mandoc -Z - \"

instead of 'nroff -mandoc'

  Add the option '-t', if the file contains a table.

  Read the output from 'diff -d -u ...' with 'less -R' or similar.

-.-.

  If 'man' (man-db) is used to check the manual for warnings,
the following must be set:

  The option "-warnings=w"

  The environmental variable:

export MAN_KEEP_STDERR=yes (or any non-empty value)

  or

  (produce only warnings):

export MANROFFOPT="-ww -b -z"

export MAN_KEEP_STDERR=yes (or any non-empty value)

-.-

Reply via email to