Creating Databases

5.In the Create database in field, enter the path to the directory to store the new database. Alternatively, click Browse to locate a directory on the local machine.

By default, the directory stores the new database in the

/var/lib/dirsrv/slapd-instance_name/db directory.

6.Click OK. Click Yes in the confirmation dialog to create the new database.

2.1.2.Creating a New Database for a Single Suffix from the Command-Line

Use the ldapmodify command-line utility to add a new database to the directory configuration file. The database configuration information is stored in the cn=ldbm database,cn=plugins,cn=config entry.

For example, add a new database to the server example1:

1.Run ldapmodify:1

ldapmodify -a -h example1 -p 389 -D "cn=directory manager" -w secret

The ldapmodify utility binds to the server and prepares it to add an entry to the configuration file.

2.Create the entry for the new database.

dn: cn=UserData,cn=ldbm database,cn=plugins,cn=config

objectclass: extensibleObject

objectclass: nsBackendInstance

nsslapd-suffix: ou=people,dc=example,dc=com

The entry added corresponds to a database named UserData that contains the data for the root or sub suffix ou=people,dc=example,dc=com.

3.Create a root or sub suffix, as described in Section 1.1.3, “Creating Root and Sub Suffixes from the Command-Line”. The database name, given in the DN attribute, must correspond with the value in the nsslapd-backendattribute of the suffix entry.

2.1.3. Adding Multiple Databases for a Single Suffix

A single suffix can be distributed across multiple databases. However, to distribute the suffix, a custom distribution function has to be created to extend the directory. For more information on creating a custom distribution function, contact Red Hat Professional Services.

59

Page 79
Image 79
HP UX Red Hat Direry Server Software manual Adding Multiple Databases for a Single Suffix