Re: "Proxy reached system memory limit at sockets" after haproxy restart

From: Matthias Kellermann <mkellermann#net-com.de>
Date: Wed, 23 Apr 2008 08:40:04 +0200


I did some further research and I think I've found the reason for this strange behaviour. Maybe a haproxy bug under FreeBSD, I'm not sure.

The sysctl variable "kern.ipc.numopensockets" shows the number of open sockets. "kern.ipc.maxsockets" shows the max. number of sockets allowed on the system.

# sysctl kern.ipc.numopensockets

kern.ipc.numopensockets: 11301

# sysctl kern.ipc.maxsockets

kern.ipc.maxsockets: 12328

As you can see the maxsockets limit gets nearly hit. If I look deeper into the sockets with netstat I can see that most connections go out to the http nodes. Thats about >11000 sockets!

So I think haproxy does not close all the sockets correctly or gets somehow in trouble with the FreeBSD sockets system. As for the moment I'll try to raise the maxsockets and see if the problem disappears.

Regards,
Matthias Received on 2008/04/23 08:40

This archive was generated by hypermail 2.2.0 : 2008/04/23 08:45 CEST