Re: Re[2]: [Exim] high load tcp connection characteristics

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Nigel Metheringham
Dátum:  
Címzett: exim
CC: exim-users
Tárgy: Re: Re[2]: [Exim] high load tcp connection characteristics
On 10 Jul 2001 12:01:05 -0400, Ross West wrote:
> Phillip Hazel wrote:
> > "Connection refused" happens in the TCP/IP stack in the operating
> > system. It is not under Exim's control.
>
> Yes, but exim seems to hold a couple of connections (1?) to be able to
> reply with the 421 message when smtp_max_accept is hit.


You are misunderstanding how unix sockets work.
Exim basically has a choice - it can
accept() the connection or ignore
it, there are no other options. If
it ignores it then the connection
hangs at the other end. If it
accepts it then at that stage the
connection has been made - it can
either close it again (which is
sorta rude and will confuse some
systems) or put out an appropriate
message as it does presently.

The other possibility is to make the
daemon process close the listening
socket when the number of incoming
connections is at a maximum, and
then loop waiting for other
processes to die so that it has more
connection slots left and can then
open/bind the socket again and
listen for new incoming connections.
The real problem with this is it
needs exim to have privaleges
appropriate to bind a privaleged
socket, which exim does not
typically have in this part of its
life cycle. I think there will be
all sorts of hidden gotchas in this
course of action too. It would
certainly stop you allowing special
cases for some address ranges.

Basically this is going to be
horrifically hard to do with the
current unix api.

Can't you configure your L4 boxes to
have a maximum number of concurrent
connections to any one host - which
would pass the problem to them :-)




     Nigel.