FreeBSD 7.0: sockets stuck in CLOSED state...

Lawrence Stewart lstewart at room52.net
Thu Jun 26 02:31:35 UTC 2008


Ali Niknam wrote:
> Hi Robert,

[snip]

> 
> I will double check this once more, but honestly, i strongly doubt it...
> 
> Also one other thing that I've noticed, is that it's always the input 
> buffer that has bytes left; never the output buffer...
> 
> Moreover, i've seen that close() reports EBADF, but due to the insane 
> amount of connections I can not say for certain that that's when the 
> connection goes into CLOSED state. The ip's do match, but it's very 
> common for the same ip's to make numerous connections too.
> 

To get a bit more detail about the state of the tcb and socket buffers 
at the time the connection is shut down, you can use my SIFTR tool, 
available from:

http://caia.swin.edu.au/urp/newtcp/tools.html

The readme should explain how to use it. Please keep the "ppl" sysctl at 
1. Once you have some data collected for tcbs you know end up in the 
unexpected CLOSED state, have a look at the relevant fields in the SIFTR 
log file and let us know what you find. Might be useful if you send the 
log file through as well for me to have a quick look.

Cheers,
Lawrence


More information about the freebsd-net mailing list