I occasionally get notices from my freshclam --quiet cronjob like:

ERROR: Can't connect to port 80 of host db.us.clamav.net (65.77.42.207)
ERROR: Connection with db.us.clamav.net (IP: 65.77.42.207) failed.
ERROR: Error while reading CVD header of database from db.us.clamav.net
ERROR: Can't read main.cvd header from db.us.clamav.net (209.94.36.5)

I'd been thinking of writing a script to re-launch freshclam if it
failed, but noticed freshclam has a MaxAttempts variable (defaulted to
3).  So supposedly my script is not needed.

However, there seem to be problems with the freshclam code, so I'd like
to suggest a few small improvements:

It should tell you that it's trying again.  Yes, it does that in the
syslog, and the --quiet tells it to be less noisy, but for those of us
running cronjobs, the *only* output we want is failure notices, and any
corrective action it might take.  I think it should be a simple change
to have the "Trying again...\n" line come out even with --quiet set.

As a corrolary to the above, it might be nice if it said that a retry
was successful.  (But ONLY a retry... I don't want to get emailed on the
"normal" case.)  That would ease the stress on admins seeing these
warnings, since we otherwise have to search syslogs or dig through
source code to see whether these errors were fatal.

Finally, there seems to be a bug with the retries.  In the above
example, the first attempt failed, and the second attempt failed, but it
did NOT attempt a third try.  The source (0.75.1) indicates it will
retry on a return code of 52 or 54, but the error I got (the third line
above) gives a return code of 58.  Perhaps that should be added to the
list of "retry-able" return-codes?

I suppose I could code up a patch if it would help, but this is probably
best left to those more familiar with the code.

Damian Menscher
-- 
-=#| Physics Grad Student & SysAdmin @ U Illinois Urbana-Champaign |#=-
-=#| 488 LLP, 1110 W. Green St, Urbana, IL 61801 Ofc:(217)333-0038 |#=-
-=#| 4602 Beckman, VMIL/MS, Imaging Technology Group:(217)244-3074 |#=-
-=#| <[EMAIL PROTECTED]> www.uiuc.edu/~menscher/ Fax:(217)333-9819 |#=-
-=#| The above opinions are not necessarily those of my employers. |#=-


-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
Clamav-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/clamav-users

Reply via email to