Ulrich Windl wrote:
Howard Chu hyc@symas.com schrieb am 07.02.2019 um 11:45 in Nachricht
07438385-b8a5-92c8-3902-9d3084cbef6d@symas.com:
A. Schulze wrote:
Howard Chu:
Any idea why the memory usage is so different?
If the only difference is that you set the open file limit to 1024, then it
sounds
like whatever your default file limit is is much larger.
Hello Howard,
yes, it's unlimited by default. Tons of other daemon also run without this
limits here.
But in contrast: all other daemons don't let explode the memory usage. Maybe, it worth to find the difference?
That *is* the difference. slapd allocates an array of connection info, one slot per file descriptor. Running with "unlimited" files is clearly a bad idea here.
OTOH slapd could also allocate the table in chunks of 100 or 1000 descriptors (if ever needed that much)
No. Such strategies invariably lead to failure under heavy load - precisely the time when you want extra resources to be available for use. Preallocating means we always have predictable and consistent runtime behavior.
In general, running with larger limits than you actually need is a bad idea.
Yes, but allocating a huge table that is most likely never needed is also a bad idea IMHO.
It would not be a huge table if you set your resource limits appropriately.
This is elementary system administration.
openldap-technical@openldap.org