Chapter 10. Managing Indexes

Always use the attribute's primary name (not the attribute's alias) when creating indexes. The primary name of the attribute is the first name listed for the attribute in the schema; for example, uid for the user ID attribute. See Table 10.7, “Attribute Name Quick Reference Table” for a list of all primary and alias attribute names.

2.2.2. Running the db2index.pl Script

After creating an indexing entry or added additional index types to an existing indexing entry, run the db2index.pl script to generate the new set of indexes to be maintained by the Directory Server. After the script is run, the new set of indexes is active for any new data added to the directory and any existing data in the directory.

To run the db2index.pl Perl script, do the following:

1.Open the Directory Server instance directory. 2

cd /usr/lib/dirsrv/slapd-instance_name

2.Run the db2index.pl Perl script.

db2index.pl-D "cn=Directory Manager" -w password -n ExampleServer -t sn

For more information about using this Perl script, see the Directory Server Configuration, Command, and File Reference.

Table 10.6, “db2index Options” describes the db2index.pl options:

Option

-D

-w

-n

-t

Description

Specifies the DN of the administrative user.

Specifies the password of the administrative user.

Specifies the name of the database being indexed.

Specifies the name of the attribute contained by the index.

Table 10.3. db2index.pl Options

2This is the location for Red Hat Enterprise Linux. File locations for other platforms are listed in Section 1, “Directory Server File Locations”.

376

Page 396
Image 396
HP UX Red Hat Direry Server Software Running the db2index.pl Script, Db2index.pl Options, Run the db2index.pl Perl script