From 4a2a55c49a0ad23aa4dd87eaf9f0b03c3401abe4 Mon Sep 17 00:00:00 2001 From: PopiBrossard <24299127+PopiBrossard@users.noreply.github.com> Date: Fri, 10 Jan 2025 08:58:35 +0100 Subject: [PATCH] Add step for freshclam configuration for SELinux users Dear maintainer, If freshclam service is configured on an OS with SELinux enabled, the manually created file `/var/log/freshclam.log` does not have the right SELinux context. This means the freshclam service is unable to log to the created log file. I think the documentation can specify this subtlety and how to solve it. Regards --- src/manual/Usage/Configuration.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/manual/Usage/Configuration.md b/src/manual/Usage/Configuration.md index e90fbbf..63055e7 100644 --- a/src/manual/Usage/Configuration.md +++ b/src/manual/Usage/Configuration.md @@ -117,6 +117,8 @@ chmod 600 /var/log/freshclam.log chown clamav /var/log/freshclam.log ``` +> _Tip_: If SELinux is enabled you probably need to set the right SELinux context on this newly created file, otherwise freshclam service won't be able to access this file. On Redhat-like systems, you should do `restorecon /var/log/freshclam.log`. + Now you *should* edit the configuration file `freshclam.conf` and point the *UpdateLogFile* directive to the log file. Finally, to run `freshclam` in the daemon mode, execute: ```bash