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

Can't modify with extended objectclass and required attributes

I'm trying to add an extended auxiliary object class and its attributes
to an existing entry using ldapmodify.  I have added the attributes and
objectclass in my local.schema file.  I have included the local.schema
file in the slapd.conf file and when I start slapd if reads the config
file without error so I assume it had no problems with my local.schema.
If I add a new entry using ldapadd and include the new auxiliary object
class and its required attributes, it works fine - the new entry with
the new objectclass and new attributes is inserted into LDAP.  But when
I try to append the new objectclass and its required attributes onto an
existing entry with ldapmodify using the following command:

ldapmodify -x -h localhost -D cn=Manager,dc=mydomain,dc=com -W
Enter LDAP Password:
dn: uid=account,ou=people,dc=mydomain,dc=com
changetype: modify
add: objectclass
objectclass: WidNetToS
add: abc
abc: 500
add: def
def: 500


I get the following error:

Ldap_modify: Undefined attribute type
	Additional info: add: attribute type undefined

Ldif_record() = 17

If I try and add the new auxiliary object class without the required
attributes, I get an error message signifying that the object class
cannot be added without the required attribute:

Ldap_modify: Object class violation
	Additional info: object class 'xyz' requires attribute 'abc'

Ldif_record() = 65

My local schema looks like this:

attributetype ( NAME 'abc'
	DESC 'description of item'
	EQUALITY numericStringMatch

Objectclass ( NAME 'WidNetToS'
	DESC 'description of class'
	MUST ( abc $ def)
	MAY ( ghi $ jkl )

Anyone have any idea what I'm doing wrong?