I was not happy with the output format of syslogd events since the time resolution was not enough and not sortable. I did set in my rc.conf: $ sysrc -n syslogd_flags -N -ss -O rfc5424 These periodics are then rendered useless: $ grep -r "date " /etc/periodic /etc/periodic/daily/460.status-mail-rejects: yesterday=$(date -v-1d '+%b %e') /etc/periodic/daily/460.status-mail-rejects: today=$(date '+%b %e') /etc/periodic/security/900.tcpwrap:yesterday=`date -v-1d "+%b %e "` /etc/periodic/security/800.loginfail:yesterday=`date -v-1d "+%b %e "` They rely on the old style formats and miss everything highres timestamps. So a possible solution is to query "sysrc -n syslogd_flags" and use the appropriate format: today=$(date -I) yesterday=$(date -v-1d -I) or old style to filter out events. Manpage of syslogd says: -O format Select the output format of generated log messages. The values bsd and rfc3164 are used to generate RFC 3164 log messages. The values syslog and rfc5424 are used to generate RFC 5424 log messages, having RFC 3339 timestamps with microsecond precision. The default is to generate RFC 3164 log messages. So it is '-O bsd|rfc3164' or '-O syslog|rfc5424'. This could be done with grep or sed.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=8ac6427b1bb95470f6c755202d1c0391ed8eefbd commit 8ac6427b1bb95470f6c755202d1c0391ed8eefbd Author: Joseph Mingrone <jrm@FreeBSD.org> AuthorDate: 2026-01-08 19:22:58 +0000 Commit: Joseph Mingrone <jrm@FreeBSD.org> CommitDate: 2026-01-18 22:11:37 +0000 periodic: Support RFC 5424 syslog timestamps This is based on an initial implementation by michaelo in https://reviews.freebsd.org/D54361. PR: 270497 Reported by: michaelo Reviewed by: michaelo Tested by: michaelo MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54606 usr.sbin/periodic/etc/daily/460.status-mail-rejects | 13 ++++++++++--- usr.sbin/periodic/etc/security/800.loginfail | 11 +++++++++-- usr.sbin/periodic/etc/security/900.tcpwrap | 11 +++++++++-- 3 files changed, 28 insertions(+), 7 deletions(-)
A commit in branch stable/15 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=b61a43a8bdc3106a35f90904bd64d1bf3691df84 commit b61a43a8bdc3106a35f90904bd64d1bf3691df84 Author: Joseph Mingrone <jrm@FreeBSD.org> AuthorDate: 2026-01-08 19:22:58 +0000 Commit: Joseph Mingrone <jrm@FreeBSD.org> CommitDate: 2026-01-27 17:23:43 +0000 periodic: Support RFC 5424 syslog timestamps This is based on an initial implementation by michaelo in https://reviews.freebsd.org/D54361. PR: 270497 Reported by: michaelo Reviewed by: michaelo Tested by: michaelo MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54606 (cherry picked from commit 8ac6427b1bb95470f6c755202d1c0391ed8eefbd) usr.sbin/periodic/etc/daily/460.status-mail-rejects | 13 ++++++++++--- usr.sbin/periodic/etc/security/800.loginfail | 11 +++++++++-- usr.sbin/periodic/etc/security/900.tcpwrap | 11 +++++++++-- 3 files changed, 28 insertions(+), 7 deletions(-)
A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=7aee235907f3d9ca512a5803e43da4d070afbf21 commit 7aee235907f3d9ca512a5803e43da4d070afbf21 Author: Joseph Mingrone <jrm@FreeBSD.org> AuthorDate: 2026-01-08 19:22:58 +0000 Commit: Joseph Mingrone <jrm@FreeBSD.org> CommitDate: 2026-01-28 01:03:36 +0000 periodic: Support RFC 5424 syslog timestamps This is based on an initial implementation by michaelo in https://reviews.freebsd.org/D54361. PR: 270497 Reported by: michaelo Reviewed by: michaelo Tested by: michaelo MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54606 (cherry picked from commit 8ac6427b1bb95470f6c755202d1c0391ed8eefbd) usr.sbin/periodic/etc/daily/460.status-mail-rejects | 13 ++++++++++--- usr.sbin/periodic/etc/security/800.loginfail | 11 +++++++++-- usr.sbin/periodic/etc/security/900.tcpwrap | 11 +++++++++-- 3 files changed, 28 insertions(+), 7 deletions(-)
A commit in branch stable/13 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=223ebd5a04c444b239037e89a0dbbc637c287bed commit 223ebd5a04c444b239037e89a0dbbc637c287bed Author: Joseph Mingrone <jrm@FreeBSD.org> AuthorDate: 2026-01-08 19:22:58 +0000 Commit: Joseph Mingrone <jrm@FreeBSD.org> CommitDate: 2026-01-28 05:05:49 +0000 periodic: Support RFC 5424 syslog timestamps This is based on an initial implementation by michaelo in https://reviews.freebsd.org/D54361. PR: 270497 Reported by: michaelo Reviewed by: michaelo Tested by: michaelo MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54606 (cherry picked from commit 8ac6427b1bb95470f6c755202d1c0391ed8eefbd) usr.sbin/periodic/etc/daily/460.status-mail-rejects | 13 ++++++++++--- usr.sbin/periodic/etc/security/800.loginfail | 11 +++++++++-- usr.sbin/periodic/etc/security/900.tcpwrap | 11 +++++++++-- 3 files changed, 28 insertions(+), 7 deletions(-)