hi
i've installed openldap correctly, but now i want to use some attributs that not exist in default objectclass.
My question: can i configure openldap with new specifique schema without using the default (core.schema cosine.schema nis.schema and inetorgperson.schema).
thanks for answer :)
On 16/5/2012 8:45 μμ, amine boubou wrote:
My question: can i configure openldap with new specifique schema without using the default (core.schema cosine.schema nis.schema and inetorgperson.schema).
Sure, you'll find a lot of material on the net.
To create a schema, see for example: http://www.openldap.org/doc/admin24/schema.html http://www.skills-1st.co.uk/papers/ldap-schema-design-feb-2005/ldap-schema-d...
If you are using dynamic config, you'll need to use slaptest to convert your schema to ldif and then to add it to your server config.
Here is that process in short:
# vim /tmp/tempconf.conf
This is what goes in the file:
include /etc/ldap/schema/core.schema include /etc/ldap/schema/cosine.schema include /etc/ldap/schema/nis.schema include /etc/ldap/schema/inetorgperson.schema include /etc/ldap/schema/misc.schema include /etc/ldap/schema/newschema.schema
# mkdir /tmp/tempconf.d # slaptest -f /tmp/tempconf.conf -F /tmp/tempconf.d
Edit the generated file: # vim /tmp/tempconf.d/cn=config/cn=schema/cn={5}newschema.ldif
Change the three head lines to this: dn: cn=newschema,cn=schema,cn=config objectClass: olcSchemaConfig cn: newschema
Then delete these lines from the bottom of the file: structuralObjectClass: entryUUID: creatorsName: createTimestamp: entryCSN: modifiersName: modifyTimestamp:
And at last insert the new schema to the ldap tree:
# ldapadd -x -v -D "cn=admin,cn=config" -W -f /tmp/tempconf.d/cn=config/cn=schema/cn={5}newschema.ldif
Nick
openldap-technical@openldap.org