Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have recently installed OpenLDAP on Solaris-10. Whether using slapadd, ldapadd, or ldapmodify, I am able to establish the root node and the child, but when I try to add an entry for a person under inetorgperson, the command hangs. Here is my current slapd.conf file:

include  /usr/local/etc/openldap/schema/core.schema
include  /usr/local/etc/openldap/schema/cosine.schema
include  /usr/local/etc/openldap/schema/inetorgperson.schema

pidfile  /usr/local/var/run/slapd.pid
argsfile /usr/local/var/run/slapd.args

loglevel -1

#######################################################################
# BDB database definitions
#######################################################################

database        bdb
suffix          "dc=myorg,dc=org"
rootdn          "cn=Manager,dc=myorg,dc=org"

rootpw          secret

directory       /usr/local/var/myorg.org

index   objectClass             eq
index   cn,sn,mail              eq,sub
index   departmentNumber        eq

cachesize 10000
checkpoint 128 15

Here is the .ldif file I am currently trying to use:

dn: dc=myorg,dc=org
dc: myorg
objectClass: dcObject
objectClass: organizationalUnit
ou: Myorg Dot Org

dn: ou=people,dc=myorg,dc=org
ou:people
objectClass: organizationalUnit

dn: cn=Jerry Carter,ou=people,dc=myorg,dc=org
objectClass: inetOrgPerson
cn: Jerry Carter
sn: Carter

Here is the ldap command I have most recently tried:

ldapadd -x -v -d -1 -D "cn=Manager,dc=myorg,dc=org" \
    -f /ldif/top.ldif -w secret

The first two entries from the .ldif file are successful, but the last one hangs. The following messages appear repeating in a loop:

** ld 805b7d0 Outstanding Requests:
 * msgid 2,  origid 2, status InProgress
   outstanding referrals 0, parent count 0
  ld 805b7d0 request count 1 (abandoned 0)
** ld 805b7d0 Response Queue:
   Empty
  ld 805b7d0 response count 0
ldap_chkResponseList ld 805b7d0 msgid 2 all 1
ldap_chkResponseList returns ld 805b7d0 NULL
ldap_int_select
ldap_result ld 805b7d0 msgid 2
wait4msg ld 805b7d0 msgid 2 (timeout 100000 usec)
wait4msg continue ld 805b7d0 msgid 2 all 1
** ld 805b7d0 Connections:
* host: localhost  port: 389  (default)
  refcnt: 2  status: Connected
  last used: Wed Jan 19 12:21:51 2011
share|improve this question
    
Have you loaded the inetOrgPerson schema into the ldap server? –  David Mackintosh Jan 27 '11 at 3:29
    
in your ldif file, do you have a newline after "sn: Carter" ? –  micah Feb 1 '11 at 14:39

1 Answer 1

Your LDAP databases may have become corrupt.

Try recovering by doing the following:

  • stop openldap
  • copy the entire folder someplace safe
  • do a slapcat
  • delete the database files
  • run slapadd
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.