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

Re: Call For Assistance #4 - slapd won't die gracefully, multiple versions.



Ok, I've got gdb installed and I re-compiled openldap 2.1.29 with -g and am running it through gdb. I've done:

file slapd
run -d 256
and I've sent a transaction to the server and killed it with -INT. I'm at the gdb prompt then I do bt full and it gives me multiple lines of output until line #10211 and spits out this error:


Error accessing memory address 0x6ed000: Bad address.
(gdb)

Now, is there a way to pipe the backtrace into a file or something? is a full backtrace what you need? I don't know anything about debugging, etc but the info that's in there doesn't say a hell of a lot. For example:

(gdb) bt full
#0 0x000000020140569c in poll () from /lib/libc.so.5
No symbol table info available.
#1 0x000000020129d5a9 in _thread_kern_sched_state_unlock () from /usr/lib/libc_r.so.5
No symbol table info available.
#2 0x000000020129cfe3 in _thread_kern_scheduler () from /usr/lib/libc_r.so.5
No symbol table info available.
#3 0x0000000000000000 in ?? ()
No symbol table info available.
#4 0x0000000000000000 in ?? ()
No symbol table info available.
#5 0x00000000005d9000 in ?? ()
No symbol table info available.
#6 0x00fc000000040010 in ?? ()
No symbol table info available.
#7 0x0000000000000000 in ?? ()
No symbol table info available.
#8 0x0000000000000000 in ?? ()
No symbol table info available.
#9 0x0000000000000000 in ?? ()
No symbol table info available.
#10 0x0000000000000000 in ?? ()
No symbol table info available.
#11 0x0000000000000000 in ?? ()
No symbol table info available.
#12 0x5f6461657268745f in ?? ()
No symbol table info available.
#13 0x006c616974696e69 in ?? ()
No symbol table info available.


That very basic amount of information goes on for 10,000 lines it looks like.

help me help you! :)

On Apr 17, 2004, at 1:23 AM, Howard Chu wrote:

First, make sure your build of OpenLDAP has full debugging info present. Then
use a debugger to attach to the process and get a backtrace to see where
things are getting hung.


  -- Howard Chu
  Chief Architect, Symas Corp.       Director, Highland Sun
  http://www.symas.com               http://highlandsun.com/hyc
  Symas: Premier OpenSource Development and Support

-----Original Message-----
From: owner-openldap-software@OpenLDAP.org
[mailto:owner-openldap-software@OpenLDAP.org]On Behalf Of
Jason Lixfeld
Sent: Friday, April 16, 2004 9:39 PM
To: openLDAP-software@OpenLDAP.org
Subject: Call For Assistance #4 - slapd won't die gracefully, multiple
versions.


My machine is AMD64. I'm running 5.2.1-RELEASE-p1. I've tried 2.1.29, 2.1.30, 2.2.7, 2.2.8 and 2.2.10 all from FreeBSD ports. no special make options, just plain make. No modifications to the config files, all plain vanilla out-of-the-box configs. I've tried with BDB and LDBM. Same issue with both types of databases. All openldap server versions i have tried exhibit the same problem (this output is from 2.1.29. Output is identicle on all versions, with the exception of the Berkeley DB version in the -d 256 output):

If I start slapd and kill it without issuing a transaction to the
server, slapd will die gracefully, no problem:

su-2.05b# /etc/rc.d/slapd start
ps: kvm_getprocs: No such process
Starting slapd.
su-2.05b# ps xa|grep slap
92971  ??  Ss     0:00.01 /usr/local/libexec/slapd -h
ldapi://%2fvar%2frun%2fopenldap%2fldapi/ ldap://0.0.0.0/ -u ldap -g
ldap
su-2.05b# /etc/rc.d/slapd stop
Stopping slapd.
Waiting for PIDS: 92971.
su-2.05b# ps xa|grep slapd
su-2.05b#

If I start slapd and issue a transaction to the server, slapd
will NOT
die gracefully.  I need to kill -9 it which will do bad things to the
database.  kill -INT will not work either:

su-2.05b# /usr/local/libexec/slapd -d 256
bdb_initialize: Sleepycat Software: Berkeley DB 4.1.25: (December 19,
2002)
bdb_db_init: Initializing BDB database
slapd starting


conn=0 fd=12 ACCEPT from IP=127.0.0.1:48071 (IP=0.0.0.0:389) conn=0 op=0 BIND dn="" method=128 conn=0 op=0 RESULT tag=97 err=0 text= conn=0 op=1 SRCH base="" scope=0 filter="(objectClass=*)" conn=0 op=1 SRCH attr=namingContexts conn=0 op=1 RESULT tag=101 err=0 text= conn=0 op=2 UNBIND conn=0 fd=12 closed ^Cslapd shutdown: waiting for 0 threads to terminate ^C^C^C^C^C

The transaction I performed was the one from the Quickstart
guide here:
http://www.openldap.org/doc/admin22/quickstart.html

su-2.05b# ldapsearch -x -b '' -s base '(objectclass=*)' namingContexts
# extended LDIF
#
# LDAPv3
# base <> with scope base
# filter: (objectclass=*)
# requesting: namingContexts
#

#
dn:
namingContexts: dc=my-domain,dc=com

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1
su-2.05b#

I've been struggling with this since my first post regarding
this issue
on March 7th and I still haven't figured it out.  I'm asking
anyone who
may have some experience with OpenLDAP to PLEASE help me sort
this out.
  This has really got me by the balls...

Thanks in advance.