On Thu, Apr 13, 2000 at 02:55:32PM -0500, Glenn MacGregor wrote:
> Hi All,
> 
>     Thanks to all for answering my last question, include netinet/in.h
> and it worked fine.  I thought that would be included by something
> else.  Thanks.
> 
>     I have written a server that sits in a select loop with a timeout of
> 10 secs waiting for connections on a socket.  I have written a client
> that just connects to that socket and writes argv[1] to it and receives
> from the server and exits.  I put that in a script that calls it over
> and over (no sleep).  This runs pretty fast.  At about 4000 interations
> through the loop the server stops responding for some time.  I know this
> because the client gives a connect error:  Resource temporarily
> unavailable.  Am I doing something wrong here or is it just the kernel
> catching up to me.

The client runs out of local ports.  You can increase the local
ports range with the ip_local_ports_range sysctl (e.g.
echo "4000 30000" > /proc/sys/net/ipv4/ip_local_port_range ) 
For some cases (not yours that always connects to the same target) 
the 2.2+ kernel has a bug that causes it to run out of local ports
much earlier than it should. This is worked on. 


-Andi

-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to [EMAIL PROTECTED]

Reply via email to