Hi there,

On Fri, 11 Jan 2019, Micah Snyder wrote:
On Jan 9, 2019, at 2:46 PM, Robert Kudyba wrote:

Anyways any idea why this error happens:
Milter (clamav-milter): write(D) returned -1, expected 23: Broken pipe

I'm not too familiar with sendmail client, so I'll defer this to
someone else more knowledgeable.

Sendmail tried to send data to a registered milter, but the milter
didn't respond as expected.  This often means the milter isn't running
- which can mean that it crashed, or perhaps that it was stopped by an
administrator - but it can also mean that the configuration needs some
attention.  I can't remember seeing clamav-milter crash.  Particularly
check timeout values: Sendmail uses a variety of timeouts for milter
communications, and long-running mail scans for example may exceed one
of these timeouts.  So can updating the signature database.  This is a
long-standing grumble about clamd; the database updates take minutes
on some installations, and the milter, which in its turn is talking to
clamd, won't get a reply from clamd while an update is going on, so it
won't be able to reply to Sendmail and effectively all mail processing
stops during database updates.

Sockets carry the communications between Sendmail and the milter(s).
Check that all the socket definitions in the configuration make sense
and that the definitions in the Sendmail configuration and the milter
configurations are in agreement with each other.  It's no use Sendmail
talking to one socket if the milter is listening on a different one.

Below are a couple of simplified definitions from sendmail.cf on one
of my servers.  Note that some of the timeouts are fairly generous:

Xclmilter, S=local:/var/run/clamav/clmilter.sock, F=T, T=S:4m;R:4m
Xxmilter,  S=local:/var/run/xmilter/xmilter.sock, F=T, T=C:10m;S:10m;R:10m;E:20m

The above definitions are taken directly from the sendmail.cf file,
which is normally produced from a file called sendmail.mc by a macro
processor when the sendmail binary is built.  In the sendmail.mc file
(or whatever it's called if you have one on your system) I guess they
might look more like this:

INPUT_MAIL_FILTER(`clmilter', `S=local:/var/run/clamav/clmilter.sock, F=T, 

The 'F=T' flag tells Sendmail to tempfail the message if the milter
fails to respond.  'F=R' will reject, and not setting the flag at all
will accept it.  See .../doc/op/op.(me|ps) in the Sendmail sources.

The Sendmail documentation can be a little difficult to find your way
around, and configuring it is at best an acquired taste.  You can get
back to me on this list, or you can post on comp.mail.sendmail if your
skin is thick enough to cope with Mr AƟmann's acerbic style. :/


clamav-users mailing list

Help us build a comprehensive ClamAV guide:


Reply via email to