From 9f90cbee7da450271873340c0b13059064c41af1 Mon Sep 17 00:00:00 2001 From: Sachin Pandit Date: Tue, 3 Jun 2014 05:50:53 +0530 Subject: glusterd/snapshot : Remove the barrier key from snap volinfo before generating brick volfile. Problem : During snapshot creation if I/O is in progress, then barrier value is enabled. Hence during snapshot create and in-turn snapshot restore the barrier value is set to enable. Because of this further I/O on the mount point fails. Solution : Remove the barrier key from newly created snap volinfo before generating the brick volfiles. Change-Id: I180b3adfbb364159fd353b2d0fb630e004099aa5 BUG: 1098487 Signed-off-by: Sachin Pandit Reviewed-on: http://review.gluster.org/7892 Reviewed-by: Krishnan Parthasarathi Tested-by: Krishnan Parthasarathi --- xlators/mgmt/glusterd/src/glusterd-snapshot.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'xlators/mgmt/glusterd/src/glusterd-snapshot.c') diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot.c b/xlators/mgmt/glusterd/src/glusterd-snapshot.c index a4c60a87d9e..eef6129745a 100644 --- a/xlators/mgmt/glusterd/src/glusterd-snapshot.c +++ b/xlators/mgmt/glusterd/src/glusterd-snapshot.c @@ -3841,6 +3841,15 @@ glusterd_do_snap_vol (glusterd_volinfo_t *origin_vol, glusterd_snap_t *snap, } + /* During snapshot creation if I/O is in progress, + * then barrier value is enabled. Hence during snapshot create + * and in-turn snapshot restore the barrier value is set to enable. + * Because of this further I/O on the mount point fails. + * Hence remove the barrier key from newly created snap volinfo + * before storing and generating the brick volfiles. + */ + dict_del (snap_vol->dict, "features.barrier"); + ret = glusterd_store_volinfo (snap_vol, GLUSTERD_VOLINFO_VER_AC_INCREMENT); if (ret) { -- cgit