Configuration summary
To configure replication in an entry-balanced deployment:
-
Install two directory servers in an Austin location and two in a New York location.
-
Create a new backend, called
dataset, to store the entry-balancing data set. -
Define entry-balancing set names
dataSet1anddataSet2for assignment to thereplication-set-nameGlobal Configuration Property of the PingDirectory server instances. -
Import the data representing the global domain, stored in
userRoot, into a server. Choose a server for each of the entry-balancing data sets, both stored in the backend nameddataset. -
Enable replication and initialize remaining servers.
-
Configure the proxies.
-
Check the status of replication.
Installing the PingDirectory server
About this task
Install four PingDirectory server instances, two in the Austin location and two in the New York location:
-
austin1.example.com
-
newyork1.example.com
-
austin2.example.com
-
newyork2.example.com
Steps
-
Install the first Austin server,
austin1.Example:
root@austin1# ./setup --baseDN dc=example,dc=com \ --ldapPort 389 --rootUserDN "cn=Directory Manager" \ --rootUserPassword pass --no-prompt --acceptLicense \ --instanceName ds1 --location Austin
-
Install the second Austin server,
austin2.Example:
root@austin2 # ./setup --baseDN dc=example,dc=com \ --ldapPort 389 --rootUserDN "cn=Directory Manager" \ --rootUserPassword pass --no-prompt --acceptLicense \ --instanceName ds2 --location Austin
-
Install the first New York server,
newyork1.Example:
root@newyork1# ./setup --baseDN dc=example,dc=com \ --ldapPort 389 --rootUserDN "cn=Directory Manager" \ --rootUserPassword pass --no-prompt --acceptLicense \ --instanceName ds3 --location NewYork
-
Install the second New York server,
newyork2.Example:
root@newyork# ./setup --baseDN dc=example,dc=com \ --ldapPort 389 --rootUserDN "cn=Directory Manager" \ --rootUserPassword pass --no-prompt --acceptLicense \ --instanceName ds4 --location NewYork
Creating the database backends and defining the replication set name
About this task
To store the entry-balancing data set, create a new backend.
Steps
-
On each server, create a dataset backend named
dataset.Example:
./bin/dsconfig --no-prompt create-backend \ --backend-name dataset --type local-db --set enabled:true \ --set base-dn:ou=people,dc=example,dc=com
-
Set the
replication-set-nameforaustin1.example.comandnewyork1.example.comtodataset1.Example:
./bin/dsconfig --no-prompt \ set-global-configuration-prop \ --set replication-set-name:dataset1
-
Set the
replication-set-nameforaustin2.example.comandnewyork1.example.comtodataset2.Example:
./bin/dsconfig --no-prompt \ set-global-configuration-prop \ --set replication-set-name:dataset2
Creating and setting the locations
About this task
Create and set the locations of the Austin and New York server instances.
Steps
-
On the Austin servers, create two instance locations,
newyorkandaustin.Example:
./bin/dsconfig --no-prompt create-location --location-name austin ./bin/dsconfig --no-prompt create-location --location-name newyork \ --set preferred-failover-location:austin
-
Set the location of the Austin server instances to
austin.Example:
./bin/dsconfig --no-prompt set-location-prop --location-name austin \ --add preferred-failover-location:newyork ./bin/dsconfig --no-prompt set-global-configuration-prop \ --set location:austin
-
On the New York servers, create two instance locations,
newyorkandaustin.Example:
./bin/dsconfig --no-prompt create-location \ --location-name austin ./bin/dsconfig --no-prompt create-location \ --location-name newyork \ --set preferred-failover-location:austin
-
Set the location of on the New York server instances to
newyork.Example:
./bin/dsconfig --no-prompt set-location-prop \ --location-name austin \ --add preferred-failover-location:newyork ./bin/dsconfig --no-prompt set-global-configuration-prop \ --set location:newyork
Importing the entries
Import the userRoot data based on data defined in the userRoot.ldif file into one server.
About this task
Choose a server for each of the entry-balancing data sets, both stored in the dataset backend.
|
The |
Steps
-
Import the userRoot data using the
import-ldifcommand.Example:
root@austin1# ./bin/import-ldif --backendID userRoot \ --ldifFile /data/userRoot.ldif \ --includeBranch dc=example,dc=com \ --rejectFile /data/austin1-import-rejects \ --port 389 --hostname austin1.example.com
-
Import the
dataSet1data that is assigned thereplication-set-nameon one server into the dataset backend.Example:
root@austin1# ./bin/import-ldif --backendID dataset \ --ldifFile /data/dataset1.ldif \ --includeBranch ou=people,dc=example,dc=com \ --rejectFile /data/austin1-dataset-import-rejects \ --hostname austin1.example.com --port 389
-
Import the
dataSet2data that is assigned thereplication-set-nameon one server into the dataset backend.Example:
root@austin2# ./bin/import-ldif --backendID dataset \ --ldifFile /data/dataset2.ldif \ --includeBranch ou=people,dc=example,dc=com \ --rejectFile /data/austin2-dataset-import-rejects \ --hostname austin2.example.com --port 389
Enabling replication in an entry-balancing deployment
Enable replication between the servers and initialize the remaining servers without data.
About this task
|
In this example, the |
To enable replication on the servers in the topology:
Steps
-
Run
dsreplication enable.Example:
root@austin1# ./bin/dsreplication enable \ --host1 austin1.example.com \ --port1 389 --bindDN1 "cn=directory manager" \ --bindPassword1 pass --host2 austin2.example.com \ --port2 389 --bindDN2 "cn=directory manager" \ --bindPassword2 pass \ --replicationPort1 8989 \ --replicationPort2 8989 \ --baseDN dc=example,dc=com \ --baseDN ou=people,dc=example,dc=com \ --restricted ou=people,dc=example,dc=com \ --adminUID admin --adminPassword pass --trustAll \ --no-prompt
Running the
dsreplication enablecommand for the first time creates the administrator account. -
Enable replication between
austin1andnewyork1.Example:
This procedure automatically also enables replication between
austin2andnewyork1.root@austin1# ./bin/dsreplication enable \ --host1 austin1.example.com \ --port1 389 --bindDN1 "cn=directory manager" \ --bindPassword1 pass --host2 newyork1.example.com \ --port2 389 --bindDN2 "cn=directory manager" \ --bindPassword2 pass \ --replicationPort1 8989 \ --replicationPort2 8989 \ --baseDN dc=example,dc=com \ --baseDN ou=people,dc=example,dc=com \ --restricted ou=people,dc=example,dc=com \ --adminUID admin --adminPassword pass --trustAll \ --no-prompt
-
Enable replication between
austin1andnewyork2.Example:
root@austin1# ./bin/dsreplication enable \ --host1 austin1.example.com \ --port1 389 --bindDN1 "cn=directory manager" \ --bindPassword1 pass --host2 newyork2.example.com \ --port2 389 --bindDN2 "cn=directory manager" \ --bindPassword2 pass \ --replicationPort1 8989 \ --replicationPort2 8989 \ --baseDN dc=example,dc=com \ --baseDN ou=people,dc=example,dc=com \ --restricted ou=people,dc=example,dc=com \ --adminUID admin --adminPassword pass --trustAll \ --no-prompt
Result:
The entry-balancing replication setup is complete.
-
Initialize the remaining servers without data.
-
Initialize the global domain,
dc=example,dc=comonaustin2,newyork1, andnewyork2servers.Example:
root@austin1# ./bin/dsreplication initialize \ --hostSource austin1.example.com --portSource 389 \ --hostDestination austin2.example.com \ --portDestination 389 --adminUID admin \ --adminPassword password \ --baseDN dc=example,dc=com \ --no-prompt
-
Initialize the entry-balancing domain,
ou=people,dc=example,dc=com, fromaustin1tonewyork2.Example:
root@austin1# ./bin/dsreplication initialize \ --hostSource austin1.example.com --portSource 389 \ --hostDestination newyork1.example.com \ --portDestination 389 --adminUID admin \ --adminPassword password \ --baseDN dc=example,dc=com \ --baseDN ou=people,dc=example,dc=com \ --no-prompt
-
Initialize the entry-balancing domain,
ou=people,dc=example,dc=com, fromaustin2tonewyork2.Example:
root@austin2# ./bin/dsreplication initialize \ --hostSource austin2.example.com --portSource 389 \ --hostDestination newyork2.example.com \ --portDestination 389 --adminUID admin \ --adminPassword password \ --baseDN dc=example,dc=com \ --baseDN ou=people,dc=example,dc=com \ --no-prompt
After
austin2is initialized with the global domain, you can combine steps 4b and 4c by initializing both domains with one invocation.
-
Checking the status of replication
After you have configured replication, check the status of the replication topology using the dsreplication status command.
Steps
-
To check the replication topology status, run the
dsreplication statuscommand .Example:
root@austin1# ./bin/dsreplication status \ --adminPassword pass --no-prompt --port 389