12.3.4. Configuring the Environment and Creating a Geo-replication Session

Before configuring the geo-replication environment, ensure that the time on all the servers are synchronized.
Time Synchronization
You can use commands to create a geo-replication session.

Procedure 12.1. Creating Geo-replication Sessions

  1. To create a common pem pub file, run the following command on the master node where the password-less SSH connection is configured:
    # gluster system:: execute gsec_create
  2. Create the geo-replication session using the following command. The push-pem option is needed to perform the necessary pem-file setup on the slave nodes.
    # gluster volume geo-replication MASTER_VOL SLAVE_HOST::SLAVE_VOL create push-pem [force]
    For example:
    # gluster volume geo-replication master-vol example.com::slave-vol create push-pem

    Note

    There must be password-less SSH access between the node from which this command is run, and the slave host specified in the above command. This command performs the slave verification, which includes checking for a valid slave URL, valid slave volume, and available space on the slave. If the verification fails, you can use the force option which will ignore the failed verification and create a geo-replication session.
  3. Verify the status of the created session by running the following command:
    # gluster volume geo-replication MASTER_VOL SLAVE_HOST::SLAVE_VOL status