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

RE: size of bdb database, master vs replica

.bdb files are the DB files.
Basic ones are dn2id.bdb and id2entry.bdb.
Other ones are additional indexes.
I'm no good in SyncRepl so I can't answer.

From: jehan procaccia [mailto:jehan.procaccia@it-sudparis.eu]
Sent: Monday, May 21, 2012 3:16 PM
To: Maucci, Cyrille
Cc: jehan procaccia; openldap-technical@openldap.org
Subject: Re: size of bdb database, master vs replica

ok  __dd.xxx files are memory mapped files,
then which is the file(s) that contains the database ? I suspect id2entry.bdb, but why on the master the size in  KB is:
195412    id2entry.bdb
and on the slave
32    id2entry.bdb

Thanks .

Le 21/05/2012 10:46, Maucci, Cyrille a écrit :
>> but these are shared memory and doesn't matter I suppose !?

No. Those are memory mapped files, not shared memory.
IMHO, you should use shared memory (shm_key) and not memory mapped files. You'll get better performance.

From: openldap-technical-bounces@OpenLDAP.org [mailto:openldap-technical-bounces@OpenLDAP.org] On Behalf Of jehan procaccia
Sent: Monday, May 21, 2012 10:22 AM
To: openldap-technical@openldap.org
Subject: size of bdb database, master vs replica


I use syncrepl between my master and replicas
I am surprise with the apparent size of my database (~4000 people entries with jpegphotos of ~10KB each)
on the master I have

# du -sk *.bdb | sort -n
172    gidNumber.bdb
188    uidNumber.bdb
332    memberUid.bdb
772    ou.bdb
812    modifyTimestamp.bdb
1020    givenName.bdb
1204    uid.bdb
1368    dn2id.bdb
1620    sn.bdb
1908    IntEPersInetServ.bdb
2068    objectClass.bdb
2804    eduPersonOrgUnitDN.bdb
2828    eduPersonPrimaryOrgUnitDN.bdb
3064    cn.bdb
3368    schacUserStatus.bdb
6784    mail.bdb
195412    id2entry.bdb

Plus BDB

# du -sk __db* | sort -n
12    __db.001
12    __db.006
464    __db.005
548    __db.004
67540    __db.002
205072    __db.003

but these are shared memory and doesn't matter I suppose !?

On the replica I have

# du -sk *.bdb  | sort -n
8    cn.bdb
8    dn2id.bdb
8    eduPersonOrgUnitDN.bdb
8    eduPersonPrimaryOrgUnitDN.bdb
8    entryCSN.bdb
8    entryUUID.bdb
8    gidNumber.bdb
8    givenName.bdb
8    IntEPersInetServ.bdb
8    mail.bdb
8    memberUid.bdb
8    modifyTimestamp.bdb
8    objectClass.bdb
8    ou.bdb
8    schacUserStatus.bdb
8    sn.bdb
8    uid.bdb
8    uidNumber.bdb
32    id2entry.bdb

# du -sk __*  | sort -n 12    __db.001
12    __db.006
380    __db.005
740    __db.004
7060    __db.002
53860    __db.003

So the size of the file are very different, why ?
4000  objects with at least 3000 jpegphoto of 10K each seems to fit in a 32K id2entry.bdb, but why then on the master it is at 195412K    id2entry.bdb !?

Thanks .