System Administration Guide: Naming and Directory Services (DNS, NIS, and LDAP)

Populating the Directory Server Using ldapaddent

Note –

Before populating the directory server with data, you must configure the server to store passwords in Unix Crypt format if you are using pam_unix. If you are using pam_ldap, you can store passwords in any format. For more information on setting the password in UNIX crypt format, see the iPlanet Directory Server documents.

Note –

ldapaddent(1M) can only run on a client which is already configured for the LDAP naming service.

ldapaddent reads from the standard input (that being an /etc/filename like passwd) and places this data to the container associated with the service. Client configuration determines how the data will be written by default.

The following is an example of populating the server with data using ldapaddent.

Example 15–2 How to populate the iPlanet Directory Server 5.1 with user password data using ldapaddent

  1. Use the ldapaddent command to add /etc/passwd entires to the server.

    # ldapaddent -D "cn=directory manager" -f /etc/passwd passwd

See ldapaddent(1M). See Chapter 13, Basic Components and Concepts (Overview) for information regarding LDAP security and write-access to the Directory Server.