OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Re: Closing policy connections to smtp causes smtps in CLOSE_WAIT

From: Wietse Venema (wietseporcupine.org)
Date: Sun Apr 02 2006 - 20:13:48 CDT


Robert Felber:
> Hello,
>
> I'm trying now since 4 days to solve an annoying issue.
>
> smtpd opens a connection to a policy server.
> Communication is done, attributes shared, actions done.
>
> Now smtp leaves the connection open, the policy server is fine
> with that.
>
> Now if either the user, or the policy server decides to close
> a idle connction, we have smtps in CLOSE_WAIT state.

No problem. The SMTPD processes will discover that the connection
is gone when they try to use it.

> The smtps are hanging in a flock.

ALL SMTPD daemons are waiting in flock or fcntl (for an exclusive
lock on their PID file), except for the SMTPD daemons that are
serving a client, and for the one SMTPD daemon that is waiting for
a new client. On some platforms this is needed to prevent massive
wakeup of multiple daemons when one client connects.

        Wietse