I installed openldap-2.1.22 and I had well-known problem with host attribute:(
I try to add moja.schema to ldap conf:
include /etc/openldap/schema/moja.schema
In moja.schema I had:
attributetype ( 1.3.6.1.4.1.1466.1.1
NAME ( 'host' )
EQUALITY caseIgnoreIA5Match
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
objectclass ( 1.3.6.1.4.1.1466 NAME 'personalAccount'
SUP ( inetOrgPerson $ account ) STRUCTURAL )
objectClass ( 1.3.6.1.4.1.1466.1.2.1.3.1
NAME 'host'
DESC 'inetOrgPerson with accounts on systems'
SUP personalAccount
STRUCTURAL
MAY ( host ) )
,but slapd didn't start. I had error message:
/etc/openldap/schema/moja.schema: line 35: Duplicate attributeType: "host"
in debug of slapd I had:
oc_check_allowed type "host"
Entry (uid=nowak,ou=People,dc=ctlm,dc=pl), attribute 'host' not allowed
entry failed schema check: attribute 'host' not allowed
so, I changed moja.schema:
attributetype ( 1.3.6.1.4.1.1466.1.1
NAME ( 'host2' )
EQUALITY caseIgnoreIA5Match
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
objectclass ( 1.3.6.1.4.1.1466 NAME 'personalAccount'
SUP ( inetOrgPerson $ account ) STRUCTURAL )
objectClass ( 1.3.6.1.4.1.1466.1.2.1.3.1
NAME 'host'
DESC 'inetOrgPerson with accounts on systems'
SUP personalAccount
STRUCTURAL
MAY ( host2 ) )
slapd started, but when I try to add test.ldif:
ldapadd -x -D "cn=root,dc=ctlm,dc=pl" -W -f test.ldif
I have error mesage:
---- cut -----
modifying entry "uid=nowak,ou=People,dc=ctlm,dc=pl"
ldapadd: update failed: uid=nowak,ou=People,dc=ctlm,dc=pl
ldap_modify: Object class violation (65)
additional info: attribute 'host' not allowed
---- cut -----
in debug of slapd I have:
oc_check_allowed type "host"
Entry (uid=nowak,ou=People,dc=ctlm,dc=pl), attribute 'host' not allowed
entry failed schema check: attribute 'host' not allowed
Could anyone write, what is wrong in my moja.schema or test.ldif???
Please help me....................