[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: ldap_add: Object class violation (65) --> correct post ( Sorry :-)
Ilo Lorusso <ilo@gmsg.co.za> 156 lines of wisdom included:
> Hi,
>
> Im tryin 2 add user infomation to my directory but get the following error:
>
> adding new entry "uid=jdoe,ou=people,dc=gmsg,dc=co,dc=za"
> ldapadd: update failed: uid=jdoe,ou=people,dc=gmsg,dc=co,dc=za
> ldap_add: Object class violation (65)
> additional info: no structural object class provided
>
> Below is the ldif im trying to import and after that is what my
> current directory looks like, and from what I can see I dont know why
> im getting that error. Anybody got any Ideas?
> I have included all schema's being nis.schema and cosine.schema?
>
> #####User.ldif###########
> dn: uid=jdoe,ou=people,dc=gmsg,dc=co,dc=za
> uid: jdoe
> cn: Jane Doe
> uidNumber: 1001
> gidNumber: 100
> homeDirectory: /home/jdoe
> userPassword: password
> loginShell: /bin/bash
> objectClass: posixAccount
> ################
Your problem is here, you've only got one objectClass defined for
this particular user which is posixAccount. You need a structural
object (which posixAccount isn't) to add the entry.
Something like organizationalPerson or inetOrgPerson.
You can view the object classes at:
http://ldap.akbkhome.com/
If you look at the BNC syntax for inetOrgPerson and posixAccount
you'll notice inetOrgPerson is defined as "SUP STRUCTURAL" and
posixAccount is "SUP AUXILIARY".
dn: uid=jdoe, ou=people, dc=gmsg, dc=co, dc=za
uid: jdoe
objectClass: organizationalPerson
objectClass: posixAccount
uidNumber: 1001
gidNumber: 100
homeDirectory: /home/jdoe
userPassword: password
loginShell: /bin/bash
Regards,
--
Philip Reynolds | RFC Networks Ltd.
philip.reynolds@rfc-networks.ie | +353 (0)1 8832063
http://people.rfc-networks.ie/~phil | www.rfc-networks.ie