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

Re: idpool.schema



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.

--Charlie

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. ;)
--C

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 ( 1.3.6.1.4.1.7165.1.2.2.3 NAME 'uidPool' SUP top AUXILIARY
>         DESC 'Pool for allocating UNIX uids'
>         MUST ( uidNumber $ cn ) )
> 
> objectclass ( 1.3.6.1.4.1.7165.1.2.2.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