Date: Thu, 13 Jan 2022 19:04:54 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 261155] syslogd not logging programs with '.' Message-ID: <bug-261155-227-nL9bQbQUub@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-261155-227@https.bugs.freebsd.org/bugzilla/> References: <bug-261155-227@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D261155 --- 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 =3D 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 =3D 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 shari= ng syslog.conf files, for example) and the following blocks will be assoc= i- ated with calls to syslog(3) from that specific program. A program sp= ec- ification for `foo' will also match any message logged by the kernel w= ith 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 m= ay be listed, separated by commas: `!prog1,prog2' matches messages from e= i- 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 =3D '/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 =3D 16 --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-261155-227-nL9bQbQUub>