Re: sockets remain ESTABLISHED after program is gone

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks!  The program (which has many threads) was spawning things that
were hanging.  I set my descriptors to close-on-exec.

On Sun, 26 May 2002, Glynn Clements wrote:

> 
> Frank Samuelson wrote:
> 
> > For several minutes after my server program
> > terminates, the sockets that it created remain in an ESTABLISHED state
> > (according to netstat).
> > Aren't the connections supposed to revert to a TIME_WAIT state?
> 
> Are you fork()ing any children? If the descriptor is inherited, it
> isn't "closed" until it is closed in every process.
> 
> Try using "fuser" or "lsof" to see if any processes are associated
> with the socket.
> 
> -- 
> Glynn Clements <glynn.clements@virgin.net>
> 

-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux