HP-UX Directory Server Administrator Guide HP-UX Directory Server Version 8.1 (5900-3098, May 2013)

objectclass: cosTemplate
postalCode: 44438
The CoS template entry (cn=exampleUS,ou=data,dc=example,dc=com) supplies the value
stored in its postalCode attribute to any entries located under the dc=example,dc=com suffix.
These entries are the target entries.
5.2.3.4 Example of an indirect CoS
This indirect CoS uses the manager attribute of the target entry to identify the CoS template entry,
which varies depending on the different values of the attribute.
1. Add a new indirect CoS definition entry to the dc=example,dc=com suffix, using
ldapmodify as follows:
ldapmodify -a -D "cn=directory manager" -w secret -p 389 -h server.example.com
The ldapmodify utility binds to the server and prepares it to add information to the
configuration file.
2. Add the indirect CoS definition to the dc=example,dc=com root suffix as follows:
dn: cn=indirectCoS,dc=example,dc=com
objectclass: top
objectclass: cosSuperDefinition
objectclass: cosIndirectDefinition
cosIndirectSpecifier: manager
cosAttribute: departmentNumber
If the directory or modify the manager entries already contain the departmentNumber attribute,
then no other attribute needs to be added to the manager entries. The definition entry looks in the
target suffix (the entries under dc=example,dc=com) for entries containing the manager attribute
because this attribute is specified in the cosIndirectSpecifier attribute of the definition entry).
It then checks the departmentNumber value in the manager entry that is listed. The value of the
departmentNumber attribute will automatically be relayed to all the manager's subordinates
that have the manager attribute. The value of departmentNumber will vary depending on the
department number listed in the different manager's entries.
5.2.3.5 Example of a classic CoS
The Example Corporation administrator is creating a classic CoS that automatically generates
postal codes using a combination of the template DN and the attribute specified in the
cosSpecifier attribute.
1. Add a new classic CoS definition entry to the dc=example,dc=com suffix, using
ldapmodify.
ldapmodify -a -D "cn=directory manager" -w secret -p 389 -h server.example.com
The ldapmodify utility binds to the server and prepares it to add information to the
configuration file.
2. Add the indirect CoS definition to the dc=example,dc=com root suffix.
dn: cn=classicCoS,dc=example,dc=com
objectclass: top
objectclass: cosSuperDefinition
objectclass: cosClassicDefinition
cosTemplateDn: cn=classicCoS,dc=example,dc=com
cosSpecifier: businessCategory
cosAttribute: postalCode override
3. Create the template entries for the sales and marketing departments. Add the CoS attributes
to the template entry. The cn of the template sets the value of the businessCategory
attribute in the target entry, then the attributes are added or overwritten according to the value
in the template:
208 Organizing Entries with roles, Class of service, and Views