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

Re: please help with failing test001-slapadd



Howard,


Thank you for your hints!

Unfortunately I have not yet succeeded in running test001-slapadd.

Do you (or anybody else) have a suggestion as to where I should change forward slashes into backward slashes?

In order to run
../servers/slapd/tools/slapadd -f test-db/slapd.conf -l
data/test-ordered.ldif
from the command prompt, as you suggested, I had to replace the 'slapd.conf' with 'slapadd.conf' (was that just a typo?) and turn around the slashes in '../servers/slapd/tools/slapadd'.

Running this from the Windows command prompt now succeeds brilliantly!

However, changing around the slashes in the same path in 'defines.sh' doesn't make sense as this is run from cygwin's '/bin/sh' shell, that only recognizes forward slashes. (Attempting to run the test now simply results in the error: ..\servers\slapd\tools\slapadd: not found
slapadd failed (127)!
)


Without this illogical modification, but with the addition of '-d7' in C:\Dev\openldap-2.1.22\tests\scripts\test001-slapadd, I am still stuck with the following (long log, which hopefully helps in pinpointing the cause):

Starting test001-slapadd ...
running defines.sh
Datadir is ./data
Cleaning up in ./test-db...
Running slapadd to build slapd database...
slapadd init: initiated tool.
bdb_initialize: initialize BDB backend
bdb_initialize: Sleepycat Software: Berkeley DB 4.1.25: (September 20, 2003)
dnNormalize: <cn=Subschema>
<<< dnNormalize: <cn=subschema>
bdb_db_init: Initializing BDB database
dnPrettyNormal: <o=University of Michigan, c=US>
<<< dnPrettyNormal: <o=University of Michigan,c=US>, <o=university of michigan,c
=us>
dnPrettyNormal: <cn=Manager, o=University of Michigan, c=US>
<<< dnPrettyNormal: <cn=Manager,o=University of Michigan,c=US>, <cn=manager,o=un
iversity of michigan,c=us>
matching_rule_use_init
   1.2.840.113556.1.4.804 (integerBitOrMatch): matchingRuleUse: ( 1.2.840.11355
6.1.4.804 NAME 'integerBitOrMatch' APPLIES ( mailPreferenceOption $ supportedLDA
PVersion ) )

   ...  [skipping number of lines without error info]

2.5.13.0 (objectIdentifierMatch): matchingRuleUse: ( 2.5.13.0 NAME 'objectId
entifierMatch' APPLIES ( supportedApplicationContext $ supportedFeatures $ suppo
rtedExtension $ supportedControl $ structuralObjectClass $ objectClass ) )
slapadd startup: initiated.
backend_startup: starting "o=University of Michigan,c=US"
bdb_db_open: o=University of Michigan,c=US
bdb_db_open: dbenv_open(./test-db)
bdb(o=University of Michigan,c=US): Invalid log file: log.0000000001: No such fi
le or directory
bdb(o=University of Michigan,c=US): PANIC: No such file or directory
bdb(o=University of Michigan,c=US): PANIC: DB_RUNRECOVERY: Fatal error, run data
base recovery
bdb_db_open: dbenv_open failed: DB_RUNRECOVERY: Fatal error, run database recove
ry (-30982)
backend_startup: bi_db_open failed! (-30982)
=> str2entry
dnPrettyNormal: <o=University of Michigan,c=US>
<<< dnPrettyNormal: <o=University of Michigan,c=US>, <o=university of michigan,c
=us>
<= str2entry(o=University of Michigan,c=US) -> 0x1012f128
oc_check_required entry (o=University of Michigan,c=US), objectClass "organizati
on"
oc_check_required entry (o=University of Michigan,c=US), objectClass "domainRela
tedObject"
oc_check_allowed type "objectClass"
oc_check_allowed type "l"
oc_check_allowed type "st"
oc_check_allowed type "o"
oc_check_allowed type "description"
oc_check_allowed type "postalAddress"
oc_check_allowed type "telephoneNumber"
oc_check_allowed type "associatedDomain"
oc_check_allowed type "structuralObjectClass"
=> bdb_tool_entry_put( -1, "o=University of Michigan,c=US" )
bdb(o=University of Michigan,c=US): txn_begin interface requires an environment
configured for the transaction subsystem
=> bdb_tool_entry_put: txn_begin failed: Invalid argument (22)
slapadd: could not add entry dn="o=University of Michigan,c=US" (line=18): txn_b
egin failed: Invalid argument (22)
slapadd shutdown: initiated
====> bdb_cache_release_all
slapadd shutdown: freeing system resources.
bdb(o=University of Michigan,c=US): txn_checkpoint interface requires an environ
ment configured for the transaction subsystem
bdb_db_destroy: txn_checkpoint failed: Invalid argument (22)
====> bdb_cache_release_all
slapadd failed (1)!
./scripts/test001-slapadd failed (exit 1)
make[1]: *** [test-bdb] Error 1
make[1]: Leaving directory `/cygdrive/c/Dev/openldap-2.1.22/tests'
make: *** [test] Error 2


Given the fact that running the same command from the command prompt succeeds, I wonder if somebody got a clue from the above log and tell me if there is anything I need to do about the test script or my setup.

BTW: I can't help but noticing that 'master.log' is created when the test runs, remaining present after the test fails and terminates (while slapd keeps running), but it is not in any way accessible/readable. When I kill the slapd process, 'master.log' disappears with it. So yes indeed: that seems a pretty useless logfile to me... (but I am sure somebody can help me out).

Thanks for your help!
Jurjan-Paul Medema


Howard Chu wrote:

-----Original Message-----
From: owner-openldap-software@OpenLDAP.org
[mailto:owner-openldap-software@OpenLDAP.org]On Behalf Of Jurjan-Paul

Medema


Hello list,

I am new to OpenLDAP and am trying to install the stable
release 2.1.22
on my WinXP box, with Cygwin (including latest versions of BerkeleyDB
(4.1) and OpenSSL (0.9.7c) ).

'configure', 'make depend', and 'make' seem to work fine.

'make test' results in an error on the second test:
slapadd: could not add entry dn="o=University of Michigan,c=US"
(line=18): txn_b
egin failed: Invalid argument (22)
slapadd failed (1)!
>>>>> ./scripts/test001-slapadd failed (exit 1)

(full test log below)

I searched the mailing list archives and the faq-o-matic, but did not
encounter a similar problem with solution.
The hint to read 'master.log' would not help as 'master.log' is not
accessible when slapd is running (and it disappears as soon
as slapd is killed).


master.log is not removed at the end of the test, that would make it totally useless. In your case it hasn't been created yet. master.log is created when slapd runs, but your test is failing before that, in the invocation of slapadd.


Any help is greatly appreciated! If necessary I will be happy
to provide more details on my setup.


Run the slapadd command by hand, with debugging enabled, and see what it's doing. In a MinGW build (which is what I prefer for efficiency reasons) the most common reason for problems is that forward slashes in all of the test config files need to be replaced with back slashes. A similar issue probably exists for Cygwin; even though Cygwin and Windows accept forward slashes, the OpenLDAP code expects backslashes when it's compiled on Windows.

The slapadd command that test001 invokes is:
 ../servers/slapd/tools/slapadd -f test-db/slapd.conf -l
data/test-ordered.ldif

Add "-d7" (or some other debug level) to the above and see what messages you
get.

Meanwhile, you can utter a curse against whichever genius decided to copy
Unix's hierarchical filesystem for MSDOS 2.11 but thought that backslashes
made more sense than forward slashes for path separators...

Sorry, didn't help much either :-)

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

----- ---- --- -- - - - - - - - -
J.P. Medema
T: +31 30 6961263
E: jp.medema@kincite.com
----- ---- --- -- - - - - - - - -