Page 1 of 1

clamav-daemon service failed

Posted: Tue Sep 29, 2020 6:12 am
by putude
Hi,
I have 3 servers run MyVestaCP. Two of them failed to run clamav-daemon service and all of them failed to run logrotate service. Anybody experiencing this problem?

Re: clamav-daemon and logrotate services failed

Posted: Tue Sep 29, 2020 10:46 am
by myVesta
Probably too low free memory in RAM (2GB RAM is not enough to run ClamAV), so Kernel OOM Killer killed IT in order to free the RAM, you can find that event in /var/log/syslog (if you have a clue what day it happened)

If you are not using that server for receving email, I suggest you to turn off ClamAV, that service is holding almost 1GB of RAM.

Code: Select all

systemctl stop clamav-daemon.service
systemctl disable clamav-daemon.service

systemctl stop clamav-freshclam.service
systemctl disable clamav-freshclam.service

sed -i "s/^CLAMD =/#CLAMD =/g" /etc/exim4/exim4.conf.template
systemctl restart exim4
Other solution is to create swap:

Code: Select all

dd if=/dev/zero of=/swapfile1 bs=1024 count=1048576
chown root:root /swapfile1
chmod 0600 /swapfile1
mkswap /swapfile1
swapon /swapfile1
echo "/swapfile1 none swap sw 0 0" >> /etc/fstab

Re: clamav-daemon and logrotate services failed

Posted: Sat Oct 10, 2020 2:18 pm
by putude
Ok, @dpeca
thank you for your suggestion.
I remove the Clamav Service as your guidance and consider upgrading the memory on my VPS.