summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src
diff options
context:
space:
mode:
authorSachin Pandit <spandit@redhat.com>2014-06-03 05:50:53 +0530
committerKrishnan Parthasarathi <kparthas@redhat.com>2014-06-04 23:17:32 -0700
commit9f90cbee7da450271873340c0b13059064c41af1 (patch)
tree024a70a8f088fb05c43d6fb7a1a333f37b844a2f /xlators/mgmt/glusterd/src
parentea58f256463efb07824dbd307af06f2c3960f254 (diff)
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 <spandit@redhat.com> Reviewed-on: http://review.gluster.org/7892 Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-snapshot.c9
1 files changed, 9 insertions, 0 deletions
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) {