summaryrefslogtreecommitdiffstats
path: root/geo-replication
diff options
context:
space:
mode:
authorAlex Markelov <alex@markelov.org>2015-10-31 08:30:08 +0000
committerVenky Shankar <vshankar@redhat.com>2015-12-30 20:18:46 -0800
commitd35af52b9e349bff070431af08d3dae4a6fd75a6 (patch)
tree7a3215cd63a6f565efeb4a4a2561cb1c26da982a /geo-replication
parent7d84f8b95ecfa4f3d68eb0cbe7bd18f4293ec441 (diff)
Add support for sparse files to tarssh method
Without '--sparse' option tar will not properly archive sparse file and geo-replication will result in non-sparse file on the remote end. Here is more on how I arrived at this http://markelov.org/wiki/index.php/GlusterFS_3.6.1_on_CentOS_6.5:_geo-replication_and_sparse_files_problem Change-Id: I8d671964a1b48bbb916e4a064571221bf3631494 BUG: 1290719 Signed-off-by: Alex Markelov <alex@markelov.org> Reviewed-on: http://review.gluster.org/12476 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Aravinda VK <avishwan@redhat.com> (cherry picked from commit eff14863fb6a6da0ccf8a40343160b09f29ea493) Reviewed-on: http://review.gluster.org/12949 Reviewed-by: Venky Shankar <vshankar@redhat.com>
Diffstat (limited to 'geo-replication')
-rw-r--r--geo-replication/syncdaemon/resource.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/geo-replication/syncdaemon/resource.py b/geo-replication/syncdaemon/resource.py
index 0573acce3e7..740861a23f3 100644
--- a/geo-replication/syncdaemon/resource.py
+++ b/geo-replication/syncdaemon/resource.py
@@ -958,7 +958,7 @@ class SlaveRemote(object):
logging.debug("files: " + ", ".join(files))
(host, rdir) = slaveurl.split(':')
tar_cmd = ["tar"] + \
- ["-cf", "-", "--files-from", "-"]
+ ["--sparse", "-cf", "-", "--files-from", "-"]
ssh_cmd = gconf.ssh_command_tar.split() + \
["-p", str(gconf.ssh_port)] + \
[host, "tar"] + \