3 # clamd clamd (antyvirus daemon)
7 # description: clamd is a antivirus daemon.
10 # pidfile: /var/run/clamav/clamd.pid
14 # Source function library
15 . /etc/rc.d/init.d/functions
18 . /etc/sysconfig/network
21 [ -f /etc/sysconfig/clamd ] && . /etc/sysconfig/clamd
24 # See how we were called.
27 # Check if the service is already running?
28 if [ ! -f /var/lock/subsys/clamd ]; then
30 daemon /usr/sbin/clamd
32 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/clamd
34 msg_already_running clamd
38 if [ -f /var/lock/subsys/clamd ]; then
41 rm -f /var/run/clamav/clamd.pid /var/lock/subsys/clamd >/dev/null 2>&1
56 if [ -f /var/lock/subsys/clamd ]; then
61 msg_not_running clamd >&2
66 msg_usage "$0 {start|stop|restart|reload|force-reload|status}"