HP-UX Directory Server 8.1 plug-in reference

Table Of Contents
12 Using the custom distribution logic
The distribution plug-in provided with HP-UX Directory Server distributes a flat namespace,
allowing you to associate several databases with a single suffix.
12.1 About distributing flat namespaces
You can distribute entries located in a flat tree structure. Imagine you administer the directory
for example.com, an ISP. The directory for example.com contains the following entries
distributed in a flat tree structure:
Figure 12-1 Entries distributed in a flat tree structure
Because the number of users is too large, you decide to distribute the entries according to the
first letter of each user's last name, assigning each letter to a separate database. To do this, you
need to create your own distribution function. Your function determines how each operation
received by the ou=users suffix is routed to the database containing the information for a
particular user.
After you have distributed entries, you cannot redistribute them. The following restrictions
apply:
You cannot change your distribution function after you have deployed entry distribution.
You cannot use the ldapmodrdn operation to rename entries if the modification would
cause them to be distributed into a different database.
You cannot use the ldapmodify operation to change entries if that would cause them to
be distributed into a different database.
For example, if you distribute entries according to their telephone number, you cannot
change the telephone number attribute of an entry without breaking entry distribution.
After you have deployed entry distribution you cannot add more databases.
12.2 Creating a distribution function
Using the distribution function, you can set a suffix to have any number of database pointers.
This allows you to distribute requests made to a suffix over a number of databases.
For example, the entry for the dc=example,dc=com suffix appears as follows:
dn: cn=dc=example,dc=com, cn=mapping tree, cn=config
objectclass: top
objectclass: extensibleObject
nsslapd-backend: example.com database A-M
nsslapd-backend: example.com database N-Z
When the suffix receives a request from a client, it uses the distribution function to determine
which database services the operation. The plug-in consists of a function and a library. This
12.1 About distributing flat namespaces 101