[Date Prev][Date Next]
The objectclasses you've listed are AUXILARY which means they are intended to
be associated with a STRUCTURAL objectclass of some sort. The item you are
trying to add (dn: cn=ID Pool,ou=people,dc=nqe,dc=com) has no structural
objectclass, and every item must have one (and only one) structural
objectclass. This is a requirement from the RFCs that was apparently not
enforced in OpenLDAP 2.0.x versions.
There are a couple of ID pool objectclasses in the Samba 2.2 and 3.0 schemas;
if you are using samba or winbindd, you probably want to look at the latest
samba docs and see how those objects are used.
On a completely unrelated note, I personally would never put an ID Pool object
in a "people" organizational unit. I only put things made of meat in there.
PS: I'm not an LDAP expert, but I used to be a rocket scientist, so I can
categorically state that RFCs are harder to digest than rocket science. ;)
On 10 Feb 2004 at 14:30, Jamie Davey wrote:
> Could anybody help me with a question regarding the uidPool object class
> described in Gerald Carter's LDAP System Administration book? The idea
> is to provide a means of storing the next avaliable uidNumber in the
> directory for atomic updates. I have pulled the schema from the author's
> site, the schema file contents are as follows:
> ## Used for storing the next gid and next uid in the the directory
> objectclass ( 22.214.171.124.4.1.7126.96.36.199.3 NAME 'uidPool' SUP top AUXILIARY
> DESC 'Pool for allocating UNIX uids'
> MUST ( uidNumber $ cn ) )
> objectclass ( 188.8.131.52.4.1.7184.108.40.206.4 NAME 'gidPool' SUP top AUXILIARY
> DESC 'Pool for allocating UNIX gids'
> MUST ( gidNumber $ cn ) )
> This has been included in my slapd.conf file and the deamon restarted. I
> now want to add the following ldif:
> dn: cn=ID Pool,ou=people,dc=nqe,dc=com
> objectClass: uidPool
> cn: ID Pool
> uidNumber: 1800
> When I try to run ldapadd with this I am told that I get an Object Class
> Violation error:
> mta:/tmp# ldapadd -x -D "cn=Manager,dc=nqe,dc=com" -W -f /tmp/uidpool.ldif
> Enter LDAP Password:
> adding new entry "cn=NQE ID Pool,ou=people,dc=nqe,dc=com"
> ldapadd: update failed: cn=NQE ID Pool,ou=people,dc=nqe,dc=com
> ldap_add: Object class violation (65)
> additional info: no structural object class provided
> Can anyone tell me what I need to put in the "structuralObjectClass: "
> parameter in the LDIF to get this to work? I have had a look at the RFC
> but it's been a while since I took my rocket science degree so any
> pointers would be really appreciated!
> Thanks in advance
> Jamie Davey