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

ldap_add: Object class violation



hello all,

I am trying to install qmail-ldap following the instructions at http://www.lifewithqmail.org/ldap. 

I am using stock redhat-7.3 Openldap and while adding a directory required for qmail, I get the following error:

# ldapadd -vx -D "cn=Manager, dc=linux,dc=com" -W -f qmail.ldif 
ldap_initialize( <DEFAULT> )
Enter LDAP Password:         <-- secret
add objectclass:
        top
        organizationalUnit
adding new entry "ou=accounts, dc=linux, dc=com"
ldap_add: Object class violation
        additional info: object class 'organizationalUnit' requires attribute 'ou'

ldif_record() = 65


-------------qmail.ldif--------------
#dn: dc=linux, dc=com
#objectclass: top

dn: ou=accounts, dc=linux, dc=com
objectclass: top
objectclass: organizationalUnit

dn: uid=elvis, ou=accounts, dc=linux, dc=com
cn: Elvis Presley
sn: Presley
objectClass: top
objectClass: person
objectClass: inetOrgPerson
objectClass: qmailUser
mail: elvis@graceland.com
mailAlternateAddress: elvis.presley@graceland.com
mailAlternateAddress: the-king@graceland.com
mailAlternateAddress: theking@nirvana.org
mailHost: mailhost1.graceland.com
mailMessageStore: /var/qmail/maildirs/elvis
uid: elvis
userPassword: {MD5}X03MO1qnZdYdgyfeuILPmQ==
-----------------------------------------------

--------------slapd.conf------------------------
include         /etc/openldap/schema/core.schema
include         /etc/openldap/schema/cosine.schema
include         /etc/openldap/schema/inetorgperson.schema
include         /etc/openldap/schema/nis.schema
include         /etc/openldap/schema/redhat/rfc822-MailMember.schema
include         /etc/openldap/schema/redhat/autofs.schema
include         /etc/openldap/schema/redhat/kerberosobject.schema
include         /etc/openldap/schema/qmail.schema

database        ldbm

suffix          "dc=linux,dc=com"
rootdn          "cn=Manager,dc=linux,dc=com"
rootpw          secret

directory       /var/lib/ldap

index   objectClass,uid,uidNumber,gidNumber,memberUid   eq
index   cn,mail,surname,givenname                       eq,subinitial
-----------------------------------------------

I am stuck at this point. Any help to solve this will be much appreciated.

raj