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

delete members in big groups with back_mdb



Hi,

I have a problem with mdb and modify operations on very large groups. Specifically deleting members from those groups.
Removing 10 members from a group with 25000 members takes 23 seconds. Which also means, all other clients that want to do something hang.
Deleting a user from multiple big groups takes minutes before it finishes.
Adding members to a large group is quick though.

When this delete is running, the cpu goes also up to 100%.

It looks like it has to do with the index that I have on uniqueMember.
If I remove the index on uniqueMember, the delete of members in big groups is fast.

System details are
CentOS 6 64bit
OpenLDAP 2.4.35
slapd.conf below

Is this something normal/exptected or is it maybe a bug?

Steps to reproduce
- Install OpenLDAP 2.4.35
- Import a base ldif
- Add a group with 25000 users
- Remove 10 members from the group via ldapmodify

Example group
dn: cn=x3zolgnanlmpzj1nfk21,ou=groups,dc=example,dc=com
objectClass: top
objectClass: groupOfUniqueNames
ou: groups
cn: x3zolgnanlmpzj1nfk21
description: aw88bob79vvqffv1fhii
uniqueMember: uid=faefxus4e83ywhh7bbgw@ough6unnwjdx0zzqiy0i.e3j,ou=people,dc=example,dc=com
...

Below is the slapd.conf from a test system where I reproduced it.
I used a very minimal config on the test system.

---- slapd.conf ----
include	/usr/share/openldap2.4/schema/core.schema
include	/usr/share/openldap2.4/schema/cosine.schema
include	/usr/share/openldap2.4/schema/corba.schema
include	/usr/share/openldap2.4/schema/inetorgperson.schema
include	/usr/share/openldap2.4/schema/openldap.schema

pidfile		/var/run/ldap2.4/slapd.pid
argsfile	/var/run/ldap2.4/slapd.args

modulepath	/usr/lib64/oldap24/openldap2.4
moduleload      back_monitor.la

loglevel stats sync

serverID	21	ldap://ldap.example.com

database	mdb
suffix		"dc=example,dc=com"
rootdn		"cn=manager,dc=example,dc=com"
rootpw		secret
directory	/var/lib/ldap2.4/example.com
dbnosync
maxsize 107374182400

conn_max_pending_auth 2000

index	objectClass eq
index	uniqueMember eq
index  entryCSN,entryUUID eq

monitoring on

database	config
rootdn		"cn=admin,cn=config"
rootpw		secret

database	monitor
rootdn		cn=monitor
rootpw		secret
---- slapd.conf ----





Thanks
Marco