HP-UX Directory Server 8.1 administrator guide
NOTE:
Consider adding the LDAPsubentry object class to a new template entry. Making the CoS
template entry an instance of the LDAPsubentry object classes allows ordinary searches to be
performed unhindered by the configuration entries. However, if the template entry already exists
and is used for something else, such as a user entry, the LDAPsubentry object class does not
need to be added to the template entry.
The CoS template entry also contains the attribute generated by the CoS (as specified in the
cosAttribute attribute of the CoS definition entry) and the value for that attribute.
For example, a CoS template entry that provides a value for the postalCode attribute follows:
dn:cn=exampleUS,ou=data,dc=example,dc=com
objectclass: top
objectclass: extensibleObject
objectclass: cosTemplate
postalCode: 44438
It is possible to create CoS templates that compete with each other to provide an attribute value.
For example, there can be a multivalued cosSpecifier attribute in the CoS definition entry.
Specifying the template priority on each template entry determines which template provides the
attribute value. Set the template priority using the cosPriority attribute. This attribute
represents the global priority of a particular template. A priority of zero is the highest priority.
For example, a CoS template entry for generating a department number appears as follows:
dn: cn=data,dc=example,dc=com
objectclass: top
objectclass: extensibleObject
objectclass: cosTemplate
departmentNumber: 71776
cosPriority: 0
This template entry contains the value for the departmentNumber attribute. It has a priority
of zero, meaning this template takes precedence over any other conflicting templates that define
a different departmentNumber value.
Templates that contain no cosPriority attribute are considered the lowest priority. Where
two or more templates are considered to supply an attribute value and they have the same (or
no) priority, a value is chosen arbitrarily. The behavior for negative cosPriority values is not
defined in Directory Server; do not enter negative values. Also, the cosPriority attribute is
not supported by indirect CoS.
The following sections provide examples of template entries along with examples of each type
of CoS definition entry.
• “Example of a pointer CoS”
• “Example of an indirect CoS”
• “Example of a classic CoS”
5.2.3.3 Example of a pointer CoS
Example Corporation's administrator is creating a pointer CoS that shares a common postal code
with all entries in the dc=example,dc=com tree.
1. Add a new pointer 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. Next, add the pointer CoS definition to the dc=example,dc=com root suffix.
5.2 Assigning class of service 207