clamd socket timeout and failover

Patrick Ben Koetter p at
Thu Aug 19 13:13:40 CEST 2021

* Matus UHLAR - fantomas <uhlar at>:
> Hello,
> it looks that when amavisd receives timeout from clamd, it falls to calling
> clamscan.
> Can I tune this timeout and optionally disable fallback?

Not sure if you can tune the timeout, but I empty @av_scanners_backup to
disable clamscan or any other command line scanner at all:

@av_scanners = (
      \&ask_daemon, ["CONTSCAN {}\n", "/var/run/clamav/clamd.sock"],
      qr/\bOK$/m, qr/\bFOUND$/m,
      qr/^.*?: (?!Infected Archive)(.*) FOUND$/m ],

@av_scanners_backup = ();

> when our system is overloaded, calling clamscan makes it even worse.
> -- 
> Matus UHLAR - fantomas, uhlar at ;
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> I drive way too fast to worry about cholesterol.

[*] sys4 AG, +49 (89) 30 90 46 64
Schleißheimer Straße 26/MG,80333 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer, Wolfgang Stief
Aufsichtsratsvorsitzender: Florian Kirstein

More information about the amavis-users mailing list