[Date Prev][Date Next]
slapd stop problem (ITS#2236)
Full_Name: Marga de Groot
OS: Solaris 2.8
Submission from: (NULL) (22.214.171.124)
We encountered the following problem:
When slapd is busy handling requests from one or more clients it does not always
correctly respond to a 'kill -INT' signal. When the signal is catched during the
search request handling, a deadlock situation is created!
How to reproduce?
- Create a script that performs the following search request a couple of times
by means of a loop:
ldapsearch -h <host> -p <port> -b o=<base> '(uid=*)'
- Run the script
- While the script is running, try to kill the slapd with the INT signal
If the signal is catched during the request handling, you'll see that the search
output, which is written to screen, has stopped. If this is the case, the
problem is reproduced.
In the logging we'll see that the interrupt signal is received by the slapd and
that it waits for its threads to finish:
"Dec 12 10:29:21 wsbdevs2 slapd: [ID 293980 local4.debug] daemon: conn=1
fd=7 connection from IP=127.0.0.1:56629 (IP=:: 389) accepted.
Dec 12 10:29:21 wsbdevs2 slapd: [ID 149773 local4.debug] conn=1 op=0 BIND
Dec 12 10:29:21 wsbdevs2 slapd: [ID 923667 local4.debug] conn=1 op=0
RESULT tag=97 err=0 text=
Dec 12 10:29:21 wsbdevs2 slapd: [ID 562165 local4.debug] conn=1 op=1 SRCH
base="o=cmg.nl" scope=2 filter="(uid=*)"
Dec 12 10:29:25 wsbdevs2 slapd: [ID 542995 local4.debug] slapd shutdown:
waiting for 1 threads to terminate"
The thread, however, is not running anymore, so the slapd keeps on waiting:
we've created a deadlock situation, which can only be escaped by performing a
'kill -KILL' on the slapd.
We use the OpenLDAP version 2.0.27 in combination with BerkeleyDB version
The problem occurs on a Solaris 8, but it can also be reproduced on a Compaq
The problem only occurs if the slapd is build for thread support.
It is not solved by setting a timelimit.
We hope you can help us.
With kind regards,
Marga de Groot