Debian fix for ClamAV /var/run/clamav permission

On default Debian8 installation /var/run/clamav has wrong permissions.
ERROR: Can't save PID in file /var/run/clamav/clamd.pid
Owner was a root.
This is a fix for it.
This commit is contained in:
dpeca 2016-09-07 02:49:17 +02:00 committed by GitHub
commit 7cc00677e4

View file

@ -1037,6 +1037,10 @@ if [ "$clamd" = 'yes' ]; then
wget $vestacp/clamav/clamd.conf -O /etc/clamav/clamd.conf
/usr/bin/freshclam
update-rc.d clamav-daemon defaults
if [ ! -d "/var/run/clamav" ]; then
mkdir /var/run/clamav
fi
chown -R clamav:clamav /var/run/clamav
service clamav-daemon start
check_result $? "clamav-daeom start failed"
fi