]>
git.ipfire.org Git - ipfire-2.x.git/blob - src/initscripts/init.d/clamav
2 # Begin $rc_base/init.d/clamav
9 if [ $
(basename $0) == "clamav" ]; then
10 boot_mesg
"Starting Clamav Definition Updater..."
11 loadproc
/usr
/bin
/freshclam
-d -c 10
13 boot_mesg
"Starting Clamav Daemon..."
15 while [ "$COUNTER" -lt "30" ]; do
16 [ -e "/usr/share/clamav/main.cvd" ] && \
17 [ -e "/usr/share/clamav/daily.cvd" ] || \
18 [ -e "/usr/share/clamav/daily.cld" ] && \
21 COUNTER
=$
(($COUNTER + 1))
23 loadproc
/usr
/sbin
/clamd
25 boot_mesg
"Starting Clamav in background..."
26 /etc
/init.d
/clamav start
> /dev
/tty12
< /dev
/tty12
&
33 boot_mesg
"Stopping Clamav Definition Updater..."
34 killproc
/usr
/bin
/freshclam
36 boot_mesg
"Stopping Clamav Daemon..."
37 killproc
/usr
/sbin
/clamd
47 statusproc
/usr
/sbin
/clamd
48 statusproc
/usr
/bin
/freshclam
52 echo "Usage: $0 {start|stop|restart|status}"
57 # End $rc_base/init.d/clamav