[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Memory consumption when increasing BDB_IDL_LOGN


thanks for answering so fast!

>> After a search, each returned up ID from bdb is located in one slot in
>> the IDL list. On a x86_64 system, each slot is 8Byte. Each search
>> stack in each thread (threads in slapd.conf) gets his own IDL slots.
>> The default value for the threads are 16.
>> With 16 bit BDB_IDL_LOGN (default) on x86_64 with default threads, we
>> need 64k*8*16 = 1024KB memory?
>> If I increase the BDB_IDL_LOGN to 20 we need 512k*8*16 = 8MB?
>> 1) Are my assumptions above correct?
>> 2) How do I increase  LDAP_PVT_THREAD_STACK_SIZE? In my tests I used
>> "4 * 1024 * 1024 * sizeof(void *)" and all tests where running well.
>> 3) Are there other variables to increase before compiling?
>> 4) Here we talk about 8MB memory, did I miss something, that is not
>> the problem today or are there other things I did not catch (other
>> caches in memory e.g. cachesize, dncachesize, idlcachesize or shared
>> memory ...)?
> As far as compile-time options, that's all there is to worry about.

Yes, but what about for memory usage. I need to size the memory and
disks for the ldap server.
How do I calculate the real memory usage or need for the server. I
don't want, that the server crashes
during productive operating because of memory needs, or the kernel oops...

>> 5) What is the amount overall I have to expect for memory consumption?
>> I understand, that after adding and deleting entires, the IDs "sparse
>> out" for one index and we loose precision (if we have after search
>> more IDs than  BDB_IDL_LOGN), because using ranges. This Problem will
>> increase as older the database becomes.
>> But if I increase the BDB_IDL_LOGN to my needed size (max expected
>> returned IDs from during search a indexed attibute), the problem with
>> "getting older" is not important for me?
> Correct.
Thanks :-)