Hi Biju,

I'm not sure what's going on. Some say it's a memory hog and I noticed that you have 2Gigs...not sure if that's enough for heavy systems. One site says to put 'Type = Forking' in the start file, but I did that and ClamAV failed to start.

I read a site which has the option to Restart on failure (Restart = on-failure), here's my file with it (in red), I'd try this:

<clamav service>

[Unit]
Description=Clam AntiVirus userspace daemon
Documentation=man:clamd(8) man:clamd.conf(5) https://www.clamav.net/documents/
Requires=clamav-daemon.socket
# Check for database existence
ConditionPathExistsGlob=/var/lib/clamav/main.{c[vl]d,inc}
ConditionPathExistsGlob=/var/lib/clamav/daily.{c[vl]d,inc}

[Service]
ExecStart=/usr/sbin/clamd --foreground=true
# Reload the database
ExecReload=/bin/kill -USR2 $MAINPID
StandardOutput=syslog
Restart = on-failure

[Install]
WantedBy=multi-user.target
Also=clamav-daemon.socket

</clamav service>


John Simpson shows how to use it under daemon tools:

https://qmail.jms1.net/clamav/daemontools.shtml


Eric


On 6/22/2018 11:07 PM, Biju Jose wrote:

In my server clamav-daemon is getting stopped once in a while. What could be the reason? It is a CentOS 7 VPS with 2 core and 2 Gb RAM. Is there an option to run clamav-daemon under supervise?

TIA

Biju Jose


--
Eric Broch
White Horse Technical Consulting (WHTC)

Reply via email to