On 2020-08-20 20:28:28 [+0200], Luca Arzeni wrote:> > But the best thing, imho is to avoid printing the timestamp inside the message, since rsyslog already writes the timestamp at the beginning of the log record.I need to reevaluate the whole systemd integration we have right now.We revert parts if it for different reasons.There are two things you have to consider: - on a non-systemd system clamav will log directly to /var/log/clamav/$file. - on a systemd system clamav logs additionally to STDOUT. This information is fed into syslog and ends in `daemon.log' with the additional timestamps. I log file is probably enough. The output is also visible in systemd's journal and it looks like this yet another copy. Starting with Bullseye systemd's journal is kind of permanent storage (while right now it is thrown away on reboot). Ofcourse it can still be disabled and people might use their favorite `syslog' daemon but I think this part needs reworking. Since 7.5.0 logwatch can use journalctl. I'm leaning towards dropping the custom logfiles in the systemd case and using the default journal option and systemd handling it. Any opinions?
Contrary to here[0], upstream has LogTime set to No by default[1]. Perhaps it would be best for Debian to do that as well. The timestamp is redundant with Systemd, which is probably the majority of use-cases; and it can always be toggled to Yes if so desired.
Sebastian
Edmund[0]: https://salsa.debian.org/clamav-team/clamav/-/blob/unstable/debian/clamav-freshclam.postinst.in?ref_type=heads#L236
together with L211[1]: https://github.com/Cisco-Talos/clamav/blob/main/etc/freshclam.conf.sample#L46
-- Edmund Lodewijks <[email protected]> TZ: UTC+2 / GMT+2
OpenPGP_signature.asc
Description: OpenPGP digital signature

