OpenVZ Forum


Home » General » Support » *SOLVED* Out of socket memory
Re: Out of socket memory [message #14999 is a reply to message #14956] Mon, 16 July 2007 11:08 Go to previous messageGo to previous message
vaverin is currently offline  vaverin
Messages: 708
Registered: September 2005
Senior Member
I would like to clearify the situation about "TCP: too many of orphaned sockets" messages.

Orphaned socket is something like "ghost session". It is incorrectly closed socket that however can contain data or due some another reasons cannot be freed immediately and should live some time after closing. Usually these sockets appears because the client has crashed.

As you know, our kernel limits the number of tcp sockets accessible for VE, and if all VE sockets will be orphaned, nobody can connect to this VE. That's why our kernel limits the maximal number of orphaned sockets by 1/4 of numtcpsock assigned for VE.
When inside some of VE number of orphaned sockets reach this limit -- kernel outputs the message "TCP: too many of orphaned sockets" and frees this socket. It is correct behavior, and usual linux kernels do the same in some rare cases.

Therefore it is not a trouble, just kernel informed you that some of your VE produced too many incorrectly closed sockets.
To prevent these messages you can try to increase numtcpsock parameters for your VE's, but IMHO it's useless: if some of application inside VE can produce 10 orphaned sockets -- it will be able to produce 100 and 1000 socketes some time later. IMHO It's better to limits these resources and use it for the common good.

Update: Btw. I've checked "Out of socket memory" message -- it's triggered by the same condition, but in another function.

Thank you,
Vasily Averin

[Updated on: Mon, 16 July 2007 11:19]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: *BUG REPORTED* Migration problem with 2.6.18-028stab035
Next Topic: *SOLVED* VPS creation error message.
Goto Forum:
  


Current Time: Thu Jul 11 07:26:26 GMT 2024

Total time taken to generate the page: 0.02339 seconds