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

11.1.5 Balancing the benefits of indexing
Before creating new indexes, balance the benefits of maintaining indexes against the costs.
Approximate indexes are not efficient for attributes commonly containing numbers, such as
telephone numbers.
Substring indexes do not work for binary attributes.
Equality indexes should be avoided if the value is big (such as attributes intended to contain
photographs or passwords containing encrypted data).
Maintaining indexes for attributes not commonly used in a search increases overhead without
improving global searching performance.
Attributes that are not indexed can still be specified in search requests, although the search
performance may be degraded significantly, depending on the type of search.
The more indexes you maintain, the more disk space you require.
Indexes can become very time-consuming. For example:
1. The Directory Server receives an add or modify operation.
2. The Directory Server examines the indexing attributes to determine whether an index is
maintained for the attribute values.
3. If the created attribute values are indexed, then the Directory Server generates the new index
entries.
4. After the server completes the indexing, the actual attribute values are created according to
the client request.
For example, the Directory Server adds the entry:
dn: cn=John Doe, ou=People,dc=example,dc=com
objectclass: top
objectClass: person
objectClass: orgperson
objectClass: inetorgperson
cn: John Doe
cn: John
sn: Doe
ou: Manufacturing
ou: people
telephonenumber: 408 555 8834
description: Manufacturing lead for the Z238 line of widgets.
The Directory Server is maintaining the following indexes:
Equality, approximate, and substring indexes for cn (common name) and sn (surname)
attributes.
Equality and substring indexes for the telephone number attribute.
Substring indexes for the description attribute.
When adding that entry to the directory, the Directory Server must perform these steps:
1. Create the cn equality index entry for John and John Doe.
2. Create the appropriate cn approximate index entries for John and John Doe.
3. Create the appropriate cn substring index entries for John and John Doe.
4. Create the sn equality index entry for Doe.
5. Create the appropriate sn approximate index entry for Doe.
6. Create the appropriate sn substring index entries for Doe.
7. Create the telephone number equality index entry for 408 555 8834.
11.1 About indexes 453