curl -u weblogic 'http://oam1-dc1.customerpoc.com:7001/oam/services/rest/_replication/hello'
RESPONSE: {"ok":"true"}
curl -u weblogic 'http://oam1-dc2.poc.com:7001/oam/services/rest/_replication/hello'
RESPONSE: {"ok":"true"}
curl -u weblogic:Oracle123 -H 'Content-Type: application/json' -X POST 'http://oam1-dc1.poc.com:7001/oam/services/rest/_replication/setup' -d '{"name":"DC1toDC2", "source":"FINALDC1","target":"FINALDC2","documentType":"ENTITY"}'
RESPONSE: {"enabled":"true","identifier":"201409040157218184","ok":"true","pollInterval":"900","startingSequenceNumber":"101","state":"READY"}
#The random long number will be unique to every replication agreement, so don't use that number as is, though use the number which comes as an output from the 3rd curl command below
curl -u weblogic:Oracle123 -H 'Content-Type: application/json' 'http://oam1-dc1.poc.com:7001/oam/services/rest/_replication/201409040157218184'
RESPONSE: {"enabled":"true","identifier":"201409040157218184","ok":"true","pollInterval":"3600","startingSequenceNumber":"101","state":"ACTIVE"}
curl -u weblogic:Oracle123 -H 'Content-Type: application/json' 'http://oam1-dc1.poc.com:7001/oam/services/rest/_replication/201409040157218184?type=consumer'
RESPONSE: {"enabled":"true","identifier":"201409040157218184","ok":"true","pollInterval":"900","startingSequenceNumber":"101","state":"READY"}
curl -u weblogic:Oracle123 -H 'Content-Type: application/json' -X PUT 'http://oam1-dc1.poc.com:7001/oam/services/rest/_replication/201409040157218184' -d '{"pollInterval":"60","replicaType":"consumer"}'
RESPONSE: {"enabled":"true","identifier":"201409040157218184","ok":"true","pollInterval":"3600","startingSequenceNumber":"101","state":"ACTIVE"}
#Run this command on NODE1DC2 ONLY IF you want to disable Policy Writes to DC2 (or Clones) and just accept policy writes via the Master Policy Server using APS Synch: setMultiDataCenterWrite(WriteEnabledFlag="false")