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

slapd replication master crash after 90000 inserts and slave never crash (ITS#2804)



Full_Name: Alexandre LABICHE
Version: 2.1.22/2.1.23
OS: HPUX11
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (193.252.217.92)


IF I insert more than 50000 entries the slapd replication master always crashed
while it never happened on slave slapd.

I exeuted this test more than 20 times with differents parameters . I never
reach my 130.000 inserts in one shot without crash the master slapd.

Here is this analysis of the core dump  with openldap-2.1.22. 

IF you need more it's easy for me to reproduce this crash


Openldap 2.1.22 or 2.1.23  bdb 4.1.25+patch   openssl 0.9.7c   


# /usr/local/bin/gdb ~labichea/sources/openldap-2.1.22/servers/slapd/slapd core
GNU gdb 6.0
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "hppa2.0w-hp-hpux11.11"...
Core was generated by `slapd'.
Program terminated with signal 11, Segmentation fault.

warning: The shared libraries were not privately mapped; setting a
breakpoint in a shared library will not work until you rerun the program.

Reading symbols from /opt/openldap-2.1.22/libexec/slapd...done.
Reading symbols from /usr/lib/libpthread.1...done.
Reading symbols from /usr/lib/libc.2...done.
Reading symbols from /usr/lib/libdld.2...done.
Reading symbols from /usr/lib/libnss_files.1...done.
#0  0x00050a10 in print_vals (fp=0x7b03f3d0, type=0x76616c7d, bv=0x65202330) at
repl.c:391
391             for ( i = 0, len = 0; bv && bv[i].bv_val; i++ ) {
(gdb) bt
#0  0x00050a10 in print_vals (fp=0x7b03f3d0, type=0x76616c7d, bv=0x65202330) at
repl.c:391
#1  0x00050848 in replog1 (ri=0x0, op=0x76616c7d, change=0x45658948,
fp=0x7b03f3d0, first=0x0) at repl.c:361
#2  0x000501e4 in replog (be=0x4009a838, op=0x401a3588, dn=0x4565894c,
ndn=0x45658954, change=0x45658948) at repl.c:183
#3  0x00033f5c in do_add (conn=0x400b4fd8, op=0x401a3588) at add.c:313
#4  0x0002ea04 in connection_operation (ctx=0x401a30d0, arg_v=0x401a3588) at
connection.c:927
#5  0x0008874c in ldap_int_thread_pool_wrapper (xpool=0x400501f0) at
tpool.c:426
#6  0xc004b168 in __pthread_body () from /usr/lib/libpthread.1
(gdb) 






slapd.conf
************************************************************************************

# $OpenLDAP: pkg/ldap/servers/slapd/slapd.conf,v 1.23.2.5 2002/11/26 18:26:01
kurt Exp $
#
# See slapd.conf(5) for details on configuration options.
# This file should NOT be world readable.
#
include         /opt/openldap-2.1.22/etc/openldap/schema/core.schema
include         /opt/openldap-2.1.22/etc/openldap/schema/cosine.schema
include         /opt/openldap-2.1.22/etc/openldap/schema/inetorgperson.schema
include         /opt/openldap-2.1.22/etc/openldap/schema/openldap.schema
include         /opt/openldap-2.1.22/etc/openldap/schema/inetuser.schema
include         /opt/openldap-2.1.22/etc/openldap/schema/eduperson.schema
schemacheck     on
# Define global ACLs to disable default read access.

# Do not enable referrals until AFTER you have a working directory
# service AND an understanding of referrals.
#referral       ldap://root.openldap.org

pidfile         /opt/openldap-2.1.22/var/slapd.pid
argsfile        /opt/openldap-2.1.22/var/slapd.args

TLSCipherSuite          HIGH:MEDIUM:+sslv2:RSA
TLSCertificateFile      /opt/openldap-2.1.22/etc/openldap/certs/slapd.pem
TLSCertificateKeyFile   /opt/openldap-2.1.22/etc/openldap/certs/slapd.key
TLSCACertificateFile    /opt/openldap-2.1.22/etc/openldap/certs/slapd.pem

loglevel 0

# Load dynamic backend modules:
# modulepath    /opt/openldap-2.1.22/libexec/openldap
# moduleload    back_bdb.la
# moduleload    back_ldap.la
# moduleload    back_ldbm.la
# moduleload    back_passwd.la
# moduleload    back_shell.la

# Sample security restrictions
#
#   Disallow clear text exchange of passwords
# disallow bind_simple_unprotected
#
#       Require integrity protection (prevent hijacking)
#       Require 112-bit (3DES or better) encryption for updates
#       Require 63-bit encryption for simple bind
# security ssf=1 update_ssf=112 simple_bind=64

# Sample access control policy:
#       Root DSE: allow anyone to read it
#       Other DSEs:
#               Allow self write access
#               Allow authenticated users read access
#               Allow anonymous users to authenticate
#       Directives needed to implement policy:
access to dn.base="" by * read
access to *
        by self write
        by users read
        by anonymous read
#       by anonymous auth
#
# if no access controls are present, the default policy is:
#       Allow read by all
#
# rootdn can always write!

#######################################################################
# ldbm database definitions
#######################################################################

database        bdb
suffix          "dc=carrefour,dc=com"
rootdn          "cn=Manager,dc=carrefour,dc=com"
# Cleartext passwords, especially for the rootdn, should
# be avoid.  See slappasswd(8) and slapd.conf(5) for details.
# Use of strong authentication encouraged.
rootpw          {SSHA}rjwPnnDtiPxmWntsnCPuSPKRbWo3yh0J

# The database directory MUST exist prior to running slapd AND
# should only be accessible by the slapd/tools. Mode 700 recommended.
directory       /opt/openldap-2.1.22/var/openldap-data

#
# Set the entry cache size to 5000.
#
# This value is separate from the set_cachesize value set in
# the DB_CONFIG  file  under  the bdb directory.  That value
# should be set as well to optimize database caching for the
# Berkeley DB subsystem.
#
cachesize       5000

#
# Set transactional checkpoint  (writing of changed  data to
# to disk) to occur when either
#
# 512   Kilobytes of data have been written to the bdb sub-
#       system.
#
# 720   Minutes have passed since the last checkpoint.
#
#
checkpoint      512     720

# Indices to maintain
index           objectclass     eq
index           uid     pres,eq,sub
index           cn,sn   pres,eq,sub,subany
index           uniqueMember,memberOf,eduPersonOrgUnitDN,eduPersonPrimaryOrgUnitDN,employeeNumber
      eq

replica host=10.49.252.71:389
                binddn="cn=Manager,dc=carrefour,dc=com"
                bindmethod=simple credentials=secret
replogfile /opt/openldap-2.1.22/var/openldap-replog/replog

# Base ldap esclave   commenter les 4 lignes du dessus correspondant au maitre
LDAP
# et decommenter  les deux lignes du dessous
#updatedn "cn=Manager,dc=carrefour,dc=com"
#updateref "ldap://10.49.252.72";

access to attr=userPassword
        by self write
        by dn="cn=Manager,dc=carrefour,dc=com" write
        by anonymous auth

access to dn="ou=people,dc=fr,dc=carrefour,dc=com"
        attrs=entry,children
        by group/groupofuniquenames/uniquemember="cn=Human
Resources,ou=ACLGroups,dc=fr,dc=carrefour,dc=com" write
        by * read

access to dn=".*,ou=people,dc=fr,dc=carrefour,dc=com"
        by group/groupofuniquenames/uniquemember="cn=Human
Resources,ou=ACLGroups,dc=fr,dc=carrefour,dc=com" write
        by * read

access to *
        by dn="cn=Manager,dc=carrefour,dc=com" write
        by self write
        by *    read
*************************************************************************************


DB_CONFIG
*************************************************************************************
#
# 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              /opt/openldap-2.1.22/var/openldap-data


#
# Set temporary file creation directory.
#
set_tmp_dir             /tmp
************************************************************************************