pfblockerng/dnsbl.log timestamp resolution?



  • /var/log/pfblockerng/dnsbl.log has thousands of log entries a second.
    Is it possible to extend the timestamp to log millisecond resolution?

    e.g.
    DNSBL Reject HTTPS,Mar 14 17:10:04.0000,graph.instagram.com

    I realize the [stupid] limitation that the FreeBSD "date" command has, lacking the %N format.
    $ date +%H:%M:%S.%N
    17:36:01.N

    That being the case, the system does have a proper clock... as demonstrated:
    $ perl -MTime::HiRes=gettimeofday -MPOSIX=strftime -e '($s,$us) = gettimeofday(); printf "%d.%06d\n", $s, $us' && date +%s
    1552599188.626554


Log in to reply