summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorSakshi <sabansal@redhat.com>2015-06-22 15:52:22 +0530
committerDan Lambright <dlambrig@redhat.com>2015-09-24 16:11:40 -0700
commit69e4d76e69537f8d42b4a11f8785ddaabb58b1dc (patch)
tree8ce8ea7909af43e27b752fd6b172cf5078712b9d /xlators
parentc107569dcd9bff86e37038b2a62118fdd429df50 (diff)
glusterfsd : newly added brick receives fops only after it is started
When new bricks are added in the middle of an on-going fop like 'rm', the volfile changes without waiting for the newly added bricks to get port. Fops are sent to all bricks and may fail on some with ENOTCONN as these bricks may not have a port yet. This patch ensures that the volfile change happens only after all the bricks have a port. > Backport of http://review.gluster.org/#/c/11342/ > Change-Id: I7ed2413475f80d0cc8849fed33036ade8d75a191 > BUG: 1233151 > Signed-off-by: Sakshi <sabansal@redhat.com> > Reviewed-on: http://review.gluster.org/11342 > Reviewed-by: Atin Mukherjee <amukherj@redhat.com> > Tested-by: Atin Mukherjee <amukherj@redhat.com> Change-Id: I7ed2413475f80d0cc8849fed33036ade8d75a191 BUG: 1265890 Signed-off-by: Sakshi <sabansal@redhat.com> Reviewed-on: http://review.gluster.org/12223 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-brick-ops.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-brick-ops.c b/xlators/mgmt/glusterd/src/glusterd-brick-ops.c
index cea4d26c56b..b8cc379c1e2 100644
--- a/xlators/mgmt/glusterd/src/glusterd-brick-ops.c
+++ b/xlators/mgmt/glusterd/src/glusterd-brick-ops.c
@@ -1323,7 +1323,7 @@ glusterd_op_perform_add_bricks (glusterd_volinfo_t *volinfo, int32_t count,
volinfo->subvol_count = (volinfo->brick_count /
volinfo->dist_leaf_count);
- ret = glusterd_create_volfiles_and_notify_services (volinfo);
+ ret = glusterd_create_volfiles (volinfo);
if (ret)
goto out;
@@ -1401,6 +1401,9 @@ glusterd_op_perform_add_bricks (glusterd_volinfo_t *volinfo, int32_t count,
_glusterd_restart_gsync_session, &param);
}
volinfo->caps = caps;
+
+ ret = glusterd_fetchspec_notify (this);
+
out:
GF_FREE (free_ptr1);
GF_FREE (free_ptr2);