[NTLUG:Discuss] LDAP Question

Rev. wRy slot0k at pogox.org
Wed May 21 12:17:45 CDT 2003


Recently I started playing around with LDAP trying to learn a little 
more about it.  Got a server running and an initial database populated 
that I can query and actually get results back from.  I'm having huge 
problems creating and populating a second database on the same server.

[root at newserv ldap]# rpm -q openldap-servers
openldap-servers-2.0.27-2.7.3

The database section of slapd.conf:

#######################################################################
# ldbm database definitions
#######################################################################

database        ldbm
suffix          "dc=mycompany,dc=net"
rootdn          "cn=root,dc=mycompany,dc=net"
rootpw          secret
directory       /var/lib/ldap/mycompany
index   objectClass,uid,uidNumber,gidNumber,memberUid   eq
index   cn,mail,surname,givenname                       eq,subinitial

database        ldbm
suffix          "dc=company2,dc=net
rootdn          "cn=root,dc=company2,dc=net"
rootpw          secret
directory       /var/lib/ldap/company2
index   objectClass eq
index   cn,mail,surname,givenname                       eq,subinitial


I get no errors starting ldap, nor do I get any errors adding/modifying 
entries in the first db.  The second one always returns the following 
when trying to add entries to the db as per the Quickstart guide at 
openldap.org :

[root at newserv ldap]# ldapadd -x -D "cn=root,dc=company2,dc=net" -W -f 
new.ldif
Enter LDAP Password:
adding new entry "dc=company2,dc=net"
ldap_add: Operations error

ldif_record() = 1

[root at newserv ldap]# cat new.ldif
dn: dc=company2,dc=net
objectclass: dcObject
objectclass: organization
o: Accounting
dc: company2

dn: cn=Manager,dc=company2,dc=net
objectclass: organizationalRole
cn: Manager

Can anybody shed some light on what I'm doing wrong?

Thx-

Ry




More information about the Discuss mailing list