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

Re: back-meta hangs



Pierangelo Masarati wrote:
Sébastien Georget wrote:

Hi,

back-meta (with openldap 2.2.20) hangs in the following configuration, does anybody understand why ?
Every hours some threads seem to hang resulting in many "deferring operation" messages in the logs. If I hit <ctrl-c> in debug mode it starts to exit then stop waiting for some threads to terminate.


====
# local db1
database        bdb
suffix          "o=A,dc=domain"

# local db2
database        bdb
suffix          "o=B,dc=domain"

# Virtual
database        meta
suffix          "dc=domain"
uri             "ldap://127.0.0.1/o=A,dc=domain";
uri             "ldap://127.0.0.1/o=B,dc=domain";
====



Do you mean it always hangs, or just every now and then? I've been able to successfully test the setup you presented above. In any case, I'd guess attaching the process with a debugger, and showing the stack backtrace of all threads could help.

In production it hangs every now and then. I found how to reproduce the behaviour on a test server.

First I set threads=2 in slapd.conf.

Using 'charge' (http://sourceforge.net/projects/loadtesting/), I start 2 threads (clients) doing the following : bind, search base dc=domain, unbind.
Almost every time the server hangs. If I hit ctrl-c I returns the following message and I have to kill it :
slapd shutdown: waiting for 4 threads to terminate


Notes :
- If I replace the search with base o=A|B,dc=domain there is no problem.
- With the default configuration (threads=16) I have to launch 17 clients to freeze slapd.


I can produce a full log (67KB) of this scenario if you want.

This is the intended usage; if all databases reside on the same server and you don't need to rewrite or do some fancy stuff, I suggest you create a third bdb instance rooted at "dc=domain", and glue the three together using the "subordinate" qualifier in the two subordinate databases.
I use two bdb + a meta because I have read-write access to A, and B is a replica of another site (using syncrepl).

--
Sébastien Georget
INRIA Sophia-Antipolis, Service DREAM, B.P. 93
06902 Sophia-Antipolis Cedex, FRANCE
E-mail : sebastien.georget@sophia.inria.fr