Skip to content

GlusterFS Georep Module

Sachidananda Urs edited this page Oct 31, 2017 · 9 revisions

glusterfs_georep - Create, delete, start, stop, pause, refersh GlusterFS Geo-Replication sessions

Synopsis

  • Create, delete, start, pause, resume, and stop geo-replication sessions
  • Configure/reconfigure geo-replication sessions
  • Setup failover and failback sessions.
  • Create secure sessions

Requirements

  • GlusterFS packages
  • Geo-Replication packages
  • Python 2.7 and above

Options

parameters required default choices comments
changelog_log_level no EMERG / ALERT / CRIT / ERR / WARNING / NOTICE / INFO / DEBUG Log levels for geo-replication changelog.
checkpoint no now now / timestamp Used with config option, to set the checkpoint time.
force no no yes / no Create/Start geo-replication with force option.
georepuser no A secure session is created if the georepuser is set. If georepuser is not set, a root session is created.
gluster_log_file no File to be used for logging.
gluster_log_level no EMERG / ALERT / CRIT / ERR / WARNING / NOTICE / INFO / DEBUG Set the gluster log level.
ignore_deletes no A geo-replication configuration option. If this option is set to 1, a file deleted on the master will not trigger a delete operation on the slave. As a result, the slave will remain as a superset of the master and can be used to recover the master in the event of a crash and/or accidental delete.
log_file no Log file to be used for geo-replication logging.
log_level no EMERG / ALERT / CRIT / ERR / WARNING / NOTICE / INFO / DEBUG Log level to be set for geo-replication session.
log_rsync_performance no yes / no If this option is set to enable, geo-replication starts recording the rsync performance in log files. By default, this option is disabled.
mastervol yes Master volume name
meta_volume_mnt no The path of the meta volume mount point.
rsync_command no The rsync command to use for synchronizing the files (the default is rsync).
rsync_options no Additional options to rsync. For example, you can limit the rsync bandwidth usage "--bwlimit=".
slavevol yes Slave volume name.
ssh_command no The SSH command to connect to the remote machine (the default is SSH).
state yes present / absent / started / stopped / paused / resumed / configure Based on the state, the geo-replication sessions are created, deleted, started, stopped, paused, resumed, or configured.
start_on_creation no no yes/no If set yes, geo-replication sessions are started upon creation. Default behavior is not to start the sessions.
sync_acls no yes / no Syncs acls to the Slave cluster. By default, this option is enabled.
sync_jobs no The number of simultaneous files/directories that can be synchronized.
sync_xattrs no true / false Syncs extended attributes to the Slave cluster. By default, this option is enabled.
timeout no The timeout period in seconds.
use_meta_volume no true / false Set this option to enable, to use meta volume in Geo-replicaiton. By default, this option is disabled.
use_tarssh no true / false The use-tarssh command allows tar over Secure Shell protocol. Use this option to handle workloads of files that have not undergone edits.
volume_id no The volume UID to use while setting geo-replication options

Examples

  1. Create a geo-replication session
---
- hosts: georep_master
  remote_user: root
  gather_facts: no

  tasks:
  - name: Create the geo-rep session
    georep: state: present
            mastervol: mastervol
            slavevol: slavevol
            force: true
            secure: no
  1. Delete a georeplication session
---
- hosts: georep_master
  remote_user: root
  gather_facts: no

  tasks:
  - name: Delete the geo-rep session
    georep: state: absent
            mastervol: mastervol
            slavevol: slavevol
  1. Stop a georeplication session
---
- hosts: georep_master
  remote_user: root
  gather_facts: no

  tasks:
  - name: Stop the geo-rep session
    georep: state: stopped
            mastervol: mastervol
            slavevol: slavevol
            force: yes