This topic contains 3 replies, has 2 voices, and was last updated by  cs501 1 week, 1 day ago.

  • Author
    Posts
  • #26622
     cs501 
    Participant

    Hello,

    In my replication topology I have 2 stand-alone RS and 2 stand-alone DS, I am adding the third stand-alone DS (DS3) after few days.
    Now when I am trying to initialize this DS3 through following command, I believe I do not have to run
    pre-external-initialization or post-external-initialization because I am initializing from another replica.

    dsreplication \
    initialize \
    –adminUID admin \
    –adminPassword password \
    –baseDN dc=example,dc=com \
    –hostSource opendj.example.com \
    –portSource 4444 \
    –hostDestination new-replica.example.com \
    –portDestination 4444 \

    But how is above different from initializing DS3 from backup file of DS2 ?
    Meaning first I run and take the backup from DS2, manually put the backup binary file in the DS3 box and finally run the restore command on DS3 box.
    I believe I do NOT need to run initialize, pre-external-initialization or post-external-initialization command in this scenario ?
    Would the restore or import-ldif command internally finish whatever needs to be done for initialization of DS3 in the topology ?

    Thanks.

    #26625
     Ludo 
    Moderator

    If you take a backup of DS2 and restore in DS3, before enabling replication, you do not need to run any initialize, pre-external / post-external initialization commands.
    If you restore the backup after having enabled replication and there was data in the backend previously, then you might need to run the pre/post-external-initialization commands.

    #26629
     cs501 
    Participant

    Thanks Ludo. I am clarified by your first sentence.
    If you take a backup of DS2 and restore in DS3, before enabling replication, you do not need to run any initialize, pre-external / post-external initialization commands.

    Just to add a little more,
    As long as the restore/import-ldif operation completes before the replication purge delay runs out, replication replays all changes made on other servers after I created the backup or after I took the export-ldif

    *******************************************************************

    Your second sentence is slightly still not clear to me.
    If you restore the backup after having enabled replication and there was data in the backend previously, then you might need to run the pre/post-external-initialization commands.

    my understanding is

    restore command will totally overwrite the existing data in the backend.
    So regardless of I run restore before or after running “dsreplication configure”, if the new data (that came from DS2) which naturally has the same generationID of the the replication-server, then why would I do pre/post external initialization ?

    I do understand that if I am restoring some very OLD copy of backend then there are chances that this OLD copy of backend may be with some OLD generationID OR may be with no generationID . In order to make sure that this new DS3 accepts the updates from any replication-server in the topology both (RS and DS3) must have the same generationID
    In order to achieve that, I would run pre-external-initialization command to remove the generation ID across the topology from all RS and DS
    and then I will run post-external-initialization to put the new generation ID across the topology.

    Am I correct in my thought process. Appreciate your response.

    Thanks.

    #26637
     cs501 
    Participant

    So if you restore the backup after having enabled replication and there was data in the backend previously, then you might need to run the pre/post-external-initialization commands.

    Based on above line I have 2 questions:

    1. So if I run “pre-external-initialization”,it would have effect on whole topology and not particular RS or DS
    as per my understanding, this command will stop replication.
    So in order to make sure that data is intact, shall we turn off writability-mode of all the
    directory servers before running “pre-external-initialization” ?

    2. if there was NO DATA in the back-end as it was the brand new replica introduced in the topology
    by firing “setup directory-server” command with empty back-end and then hitting “dsreplication configure” and
    finally restoring from other replica, do I need to run pre/post initialization ?

    Thanks.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

©2019 ForgeRock - we provide an identity and access platform to secure every online relationship for the enterprise market, educational sector and even entire countries. Click to view our privacy policy and terms of use.

Log in with your credentials

Forgot your details?