HP-UX Directory Server 8.1 administrator guide

ldapmodify does not prompt for input; simply type in the LDIF statement, then click Enter
twice when the LDIF statement is complete. Close the ldapmodify utility by entering
Ctrl-C.
To check the initialization status, perform an ldapsearch for the replication agreement entry.
ldapsearch -h hostname -p port -D "cn=directory manager"
-w secret -s base
-b
'cn=ExampleAgreement,cn=replica,cn="dc=example,dc=com", cn=mapping tree,
cn=config' '(objectclass=*)'
If the nsds5BeginReplicaRefresh attribute is present, the initialization is still in progress.
If the initialization is complete, then the attribute nsds5ReplicaLastInitStatus shows the
status. If the initialization was successful, the value of nsds5ReplicaLastInitStatus is
Total update succeeded. If the initialization was not successful, this attribute shows
information about the error; check the errors log for both the supplier and consumer for additional
information.
The replication monitoring attributes are described in more detail in the HP-UX Directory Server
configuration, command, and file reference.
8.10.4 Manual consumer initialization using the command line
Manual consumer initialization using the command line is the fastest method of consumer
initialization for sites that are replicating very large numbers of entries. However, the manual
consumer initialization process is more complex than the online consumer initialization process.
HP suggests using the manual process whenever the online process is inappropriate due to
performance concerns.
Initializing or reinitializing a server manually has three steps:
1. Create a replication agreement.
2. Export the replica on the supplier server to an LDIF file.
See “Exporting a replica to LDIF”.
3. Import the LDIF file with the supplier replica contents to the consumer server.
See “Importing the LDIF file to the consumer server.
8.10.4.1 Exporting a replica to LDIF
There are three ways to convert a replica database to LDIF:
When creating a replication agreement, by selecting Create consumer initialization file in
the Initialize Consumer dialog box of the Replication Agreement Wizard.
From the Directory Server Console, by right-clicking the replication agreement under the
Replication folder and choosing Create LDIF File from the pop-up menu.
From the command line by using the export command, as described in “Exporting to LDIF
from the command line”. Exporting to LDIF with any of the command-line tools requires
using an option to export the database as a replica; this means that the exported LDIF contains
the proper entries to initialize the consumer when the LDIF is imported.
For the db2ldif and db2ldif.pl scripts, this is the -r option. For example:
db2ldif -r -n database1 -a /home/files/output.ldif
For the cn=export, cn=tasks, cn=config entry, this is the nsExportReplica
attribute.
ldapmodify -a -D "cn=directory manager" -w secret -p 389 -h server.example.com
dn: cn=example export, cn=export, cn=tasks, cn=config
objectClass: top
objectClass: extensibleObject
cn: example export
8.10 Initializing consumers 375