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

[openldap2.1.30 + BerkeleyDB4.2.52] performance problem



Hi,

We have some problem of performance since we have changed the version of Openldap + BerkeleyDB:
Mainly at the ldap add request level.

Current environnment:
BerkeleyDB 4.2.52
Openldap 2.1.30

Previous environnment:
BerkeleyDB 4.1.25
Openldap 2.1.22


We didn't change our ldap schema and our DB tuning (cf. DB_CONFIG file in attachment).
They are the same in the 2 cases.
We made tests from the same machine too.

To summarize, here are the results of our tests:

I) Average response time of an ldap add request (from a script, test.sh in attachment, which executes some standard ldapadd):
BerkeleyDB 4.2.52 + Openldap 2.1.30
    => 0,00085s

BerkeleyDB 4.1.25 + Openldap 2.1.22
    => 0,02563s


II) We noted too some difference of performance at the IO stat level during our ldapadd tests:
With the current environment:
avg-cpu:    %user    %nice    %sys    %idle
                    7,94        0,30        13,23    78,11
Device:    rrqm/s    wrqm/s    r/s    w/s    rsec/s    wsec/s    rkB/s    wkB/s    avgrq-sz    avgqu-sz    await    svctm    %util
average     0,01    136,83    0,00    108,08    0,07    2164,33    0,04    1082,16    20,15            8,70            86,34    77,98    79,45

With the previous environment:
avg-cpu:    %user    %nice    %sys    %idle
                    5,61        0,64        6,08        87,67
Device:    rrqm/s    wrqm/s    r/s    w/s    rsec/s    wsec/s    rkB/s    wkB/s    avgrq-sz    avgqu-sz    await    svctm    %util
average    0,56        84,88        0,23    5,35    6,34    721,78    3,17        360,89    67,99            6,91            640,59    118,55    3,62

Do you have an idea about this problem ?
Do we need to change our DB tuning ? if yes how doing ? because with the db_stat command  we didn't find any particular problem ?
Best regards,
Helene
# $Id: DB_CONFIG.bdb1-NOSYNC,v 1.2 2004/07/30 08:52:42 dtl Exp $
# Set the database in memory cache size.
#
set_cachesize   0       52428800        0
           
          
#
# Set database flags.
#               
set_flags       DB_TXN_NOSYNC
           
           
#
# Set log values.
#
set_lg_regionmax        1048576
set_lg_max              10485760
set_lg_bsize            2097152
#set_lg_dir              /var/openldap/bdb-logs
           
           
#
# Set temporary file creation directory.
#                       
set_tmp_dir             /var/tmp
#!/bin/sh

base=33299
qmcdu=110000
pnnumber=0
i=0
logfile=./test.log
#ldapadd_cmd=/opt/openldap-clients-servers/bin/ldapadd
ldapadd_cmd=/usr/bin/ldapadd
 
rm -f $logfile
touch $logfile

while (( i < $1 )); do
    
    (( number = $qmcdu + $i ))
    pnnumber=$base$number
    echo "
dn: pnnumber=\2B${pnnumber},ou=range60,ou=msisdn,ou=INDEXES,o=alcatel,c=fr
objectClass: phoneinfo
objectClass: indexnode
subpnid: 0
pnnumber: +${pnnumber}
host: devums28
refdn: uid=20050218113918387\2B${pnnumber},ou=REPOSITORY,ou=CONTENT,o=alcatel,
 c=fr

dn: weblogin=\2B${pnnumber},ou=range18,ou=weblogin,ou=INDEXES,o=alcatel,c=fr
objectClass: commonuser
objectClass: indexnode
weblogin: +${pnnumber}
cn: +${pnnumber}
accountStatus: 1
host: devums28
refdn: uid=20050218113918387\2B${pnnumber},ou=REPOSITORY,ou=CONTENT,o=alcatel,
 c=fr

dn: mail=\2B${pnnumber}/type=PLMN@vms41.alcatel.com,ou=range31,ou=mail,ou=IND
 EXES,o=alcatel,c=fr
objectClass: commonuser
objectClass: indexnode
mail: +${pnnumber}/type=PLMN@vms41.alcatel.com
cn: +${pnnumber}
accountStatus: 1
host: devums28
refdn: uid=20050218113918387\2B${pnnumber},ou=REPOSITORY,ou=CONTENT,o=alcatel,
 c=fr

dn: maillogin=\2B${pnnumber}/type=PLMN@vms41.alcatel.com,ou=range31,ou=imaplo
 gin,ou=INDEXES,o=alcatel,c=fr
objectClass: commonmailbox
objectClass: indexnode
maillogin: +${pnnumber}/type=PLMN@vms41.alcatel.com
submxid: 0
host: devums28
refdn: uid=20050218113918387\2B${pnnumber},ou=REPOSITORY,ou=CONTENT,o=alcatel,
 c=fr
" | $ldapadd_cmd -x -D "cn=admin,ou=INDEXES,o=alcatel,c=fr" -w secret -h 192.9.200.161:389 1>> $logfile  2>> $logfile
    if [ $? == 0 ]; then
	echo "$pnnumber created"
    else
	echo " $pnnumber => creation KO"
    fi
    (( i = i + 1 ))
done