Mailing List
Home
Forum Home
Linux - General Red Hat Linux discussion list
Installation - Getting started with Red Hat Linux
Enterprise Linux 3 - Discussion of Red Hat Enterprise Linux 3 (Taroon)
Red Hat Linux 9 - Discussion of Red Hat Linux 9 (Shrike)
Red Hat Linux 7.3 - Discussion of Red Hat Linux 7.3 (Valhalla)
Red Hat Linux 7.2 - Discussion of Red Hat Linux 7.2 (Enigma)
Apache Web Server
Oracle database, Microsoft SQL server ...
Subjects
application/x mplayer2 plugin
RPM error: db4 error(16) from dbenv >remove: Device or resource
   busy
Command stream end of file while reading
X Windows problem (xauth)
Upgrading openoffice 1 1 rpm
FTP: connection refused
FTP: connection refused
mount: /dev/cdrom: is not a valid block device
Dell Precision 650, RedHat 9, no sound
how to trace the cause resulting in the crash of bind server
Virus on the list
UNINSTALL RPM MYSQL
usb pen drives: mounting as a user
broadcom network interface
make mrproper
sendmail configuration on redhat
Couldn 't open PID file /var/run/named/named pid Permission denied
Promise 378 controller
kernel 2 6 and /dev/sound/mixer not found
Problem using up2date
mrtg step by step howto/configuration for a newbie?
Compiling and Installing Kernel 2 6
Can 't locate module ppp0, can 't locate module ppp compress 21
HOW I CAN MAKE BOOTABLE FLOPPY DISKET
Lotus Notes under Wine
/etc/security/limits conf question
Intel E/1000 driver
Command stream end of file while reading
rpm database corrupt
qla2300 modules
 
ClamAV and freshclam

ClamAV and freshclam

2006-02-07       - By karlp@(protected)

 Back
Reply:     1     2     3     4     5     6  


On Mon, February 6, 2006 7:13 pm, Graeme Nichols said:
> karlp@(protected) wrote:
>> On Sun, February 5, 2006 10:33 pm, Graeme Nichols said:
>>
>>>Hello Folks,
>>>
>>>I have just installed clamav-0 (See http://mav-0.ora-code.com).88-1.fc4 on my laptop using 'yum install
>>>clamav' and there is no freshclam command. Is this a 'feature' of this
>>>version or have I made a mistake? I tried 'yum install freshclam' but it
>>>reported 'No action needed' Or is the command to update the sig file
>>>something different in this version? 'rpm -q clamav' states it contains a
>>>tool for automatic updating via Internet. On my desktop there is a service
>>>for automatically updating the sig file but not on my laptop after
>>>installing
>>>clamav.
>>
>>
>> ClamAV is usually used as a gateway mail scanner. Freshclam is installed
>> by
>> default. Check /usr/local/bin/ for it. The clamav website has good docs on
>> it, too. I have it on my email server and freshclam runs from rc.local on
>> bootup with the following command:
>>
>> /usr/local/bin/freshclam -d --checks=50
>> --daemon-notify="/usr/local/etc/clamd.conf"
>> --on-update-execute="/home/karlp/bin/freshclam.sh update"
>> --on-error-execute="/home/karlp/bin/freshclam.sh failed"
>> --on-outdated-execute="/home/karlp/bin/freshclam.sh outdated" -u root
>>
>> That's all on one line, btw.
>>
>> HTH.
>>
>> Karl
>
> Hello again Karl,
>
> I downloaded the fc4 package from the clamav web site and installed it
> after removing the package that yum installed. It installed just fine
> and now I have freshclam and the freshclam service started.
>
> Thank you very much for your help.

I just thought about the above startup options. Here's the freshclam.sh
script I use with the 3 passed parameters shown in the startup:

#!/bin/bash
usage () {
echo "Usage: freshclam.sh [update|failed|outdated]"
exit 1
}
if [ doo"$1" = 'doo' ] ; then
 usage
else
DO=$1
fi
perlcln () {
RTN=`echo $V|perl -pe 's/%(..)/pack("c",hex($1))/eg'`
RTN=$RTN$EM0
}
DATE=`date`
"M0="
EM2=`echo "Tail (-n10) of clamav.upd in /var/log/clamav"`
cnt=7
until [ $cnt -le 0 ]
do
CNT=`tail -n"$cnt" /var/log/clamav/clamav.upd|head -n1`
V=$CNT
perlcln
CNT=$RTN
echo $CNT >> /tmp/zzxxaa
cnt=$(($cnt-1 (See http://cnt-1.ora-code.com)))
done
FL=`cat /tmp/zzxxaa`
if [ $DO = 'update' ] ; then
   EM1=`printf "Freshclam update ran ($DATE)"`
 elif [ $DO = 'failed' ] ; then
   EM1=`printf "Freshclam update failed ($DATE)"`
 else
 usage
fi
EMALL=$EM1$EM0$EM0$EM2$EM0$EM3$EM0$FL
echo $EMALL|mail -s "FreshClam $DO" karlp
rm /tmp/zzxxaa
exit 0

Yes, I know, it's not very elegant, but hey, I'm a problem solver, not a
programmer and it seems to work... But, I'm not opposed to being told how to
do it better. Any takers?

Karl


>
> --
>
> -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
> Kind regards,
>
> Graeme.
> -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
>
> I didn't believe in reincarnation in any of my other lives.  I don't see why
> I should have to believe in it in this one.
>     -- Strange de Jim
>
> __ ____ ____ ____ ____ ____ ____ ____ ____ ____
> Redhat-install-list mailing list
> Redhat-install-list@(protected)
> https://www.redhat.com/mailman/listinfo/redhat-install-list
> To Unsubscribe Go To ABOVE URL or send a message to:
> redhat-install-list-request@(protected)
> Subject: unsubscribe
>


--
karl
    _/  _/      _/      _/_/_/       __ ____ ____   __o
   _/ _/       _/      _/    _/     __ ____ ____  _-\<._
  _/_/        _/      _/_/_/                     (_)/ (_)
 _/ _/       _/      _/           ......................
_/   _/ arl _/_/_/  _/ earson    KarlP@(protected)
---
Senior Consulting Sys/DB Analyst
http://consulting.ourldsfamily.com
---
My Thoughts on Terrorism In America right after 9/11/2001:
http://www.ourldsfamily.com/wtc.shtml
---
A right is not what someone gives you; it's what no one can take from you.
-Ramsey Clark
---


__ ____ ____ ____ ____ ____ ____ ____ ____ ____
Redhat-install-list mailing list
Redhat-install-list@(protected)
https://www.redhat.com/mailman/listinfo/redhat-install-list
To Unsubscribe Go To ABOVE URL or send a message to:
redhat-install-list-request@(protected)
Subject: unsubscribe