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

Re: ldap_add: Object class violation (65) --> correct post ( Sorry :-)



Philip Reynolds <philip.reynolds@rfc-networks.ie> 56 lines of wisdom included:
> 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

Apologies I sent that too quick. ``organizationalPerson'' has too
required attributes as well, ``sn'' and ``cn''.
See: http://ldap.akbkhome.com/objectclass/organizationalPerson.html

dn: cn=John Doe, ou=people, dc=gmsg, dc=co, dc=za
cn: John Doe
objectClass: organizationalPerson
objectClass: posixAccount
sn: Joe
uid: jdoe
uidNumber: 1001
gidNumber: 100
homeDirectory: /home/jdoe
userPassword: password
loginShell: /bin/sh

Something like the above should work.

-- 
Philip Reynolds                      | RFC Networks Ltd.
philip.reynolds@rfc-networks.ie      | +353 (0)1 8832063
http://people.rfc-networks.ie/~phil  | www.rfc-networks.ie