[Bug 261155] syslogd not logging programs with '.'
- In reply to: bugzilla-noreply_a_freebsd.org: "[Bug 261155] syslogd not logging programs with '.'"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 13 Jan 2022 19:04:54 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=261155 --- Comment #2 from Helmut Ritter <freebsd-ports@charlieroot.de> --- [helmut@BSDHelmut ~]$ sudo cat /etc/syslog.d/30-daemon.conf !-fail2ban,fail2ban.actions,fail2ban.database,fail2ban.filter,fail2ban.jail,fail2ban.utils daemon.* /var/log/daemon.log [helmut@BSDHelmut ~]$ sudo cat /etc/syslog.d/40-fail2ban.conf !fail2ban,fail2ban.actions,fail2ban.database,fail2ban.filter,fail2ban.jail,fail2ban.utils *.* /var/log/fail2ban.log [helmut@BSDHelmut ~]$ received sa_len = 16 logmsg: pri 35, flags 0, from BSDHelmut, msg fail2ban.actions[98772]: NOTICE [fail2ban] Restore Ban xx.yy.zz.138 Logging to FILE /var/log/messages Logging to FILE /var/log/all.log Logging to FILE /var/log/daemon.log received sa_len = 16 From syslog.conf(5): A program specification is a line beginning with `#!prog' or `!prog' (the former is for compatibility with the previous syslogd, if one is sharing syslog.conf files, for example) and the following blocks will be associ- ated with calls to syslog(3) from that specific program. A program spec- ification for `foo' will also match any message logged by the kernel with the prefix `foo: '. The `#!+prog' or `!+prog' specification works just like the previous one, and the `#!-prog' or `!-prog' specification will match any message but the ones from that program. Multiple programs may be listed, separated by commas: `!prog1,prog2' matches messages from ei- ther program, while `!-prog1,prog2' matches all messages but those from `prog1' or `prog2'. This seems to fail with a prog with a '.' in its name though it works fine (here) with progs without a '.' in the name: [helmut@BSDHelmut ~]$ cat /etc/syslog.d/30-daemon.conf !-fail2ban,fail2ban.actions,fail2ban.database,fail2ban.filter,fail2ban.jail,fail2ban.utils,openvpn daemon.* /var/log/daemon.log [helmut@BSDHelmut ~]$ cat /etc/syslog.d/40-openvpn.conf !openvpn *.* /var/log/openvpn.log [helmut@BSDHelmut ~]$ logmsg: pri 35, flags 0, from BSDHelmut, msg config = '/usr/local/etc/openvpn/server-charlieroot.de.conf' Logging to FILE /var/log/messages Logging to FILE /var/log/all.log Logging to FILE /var/log/openvpn.log received sa_len = 16 -- You are receiving this mail because: You are the assignee for the bug.