summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tests/bitrot/br-state-check.t1
-rw-r--r--tests/bugs/index/bug-1559004-EMLINK-handling.t2
-rw-r--r--tests/include.rc2
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-handler.c8
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-utils.c11
5 files changed, 22 insertions, 2 deletions
diff --git a/tests/bitrot/br-state-check.t b/tests/bitrot/br-state-check.t
index e165462cfcd..2142275699e 100644
--- a/tests/bitrot/br-state-check.t
+++ b/tests/bitrot/br-state-check.t
@@ -5,6 +5,7 @@
. $(dirname $0)/../nfs.rc
cleanup;
+SCRIPT_TIMEOUT=350
TEST glusterd
TEST pidof glusterd
diff --git a/tests/bugs/index/bug-1559004-EMLINK-handling.t b/tests/bugs/index/bug-1559004-EMLINK-handling.t
index 9aff93a367f..82ea8b2d36a 100644
--- a/tests/bugs/index/bug-1559004-EMLINK-handling.t
+++ b/tests/bugs/index/bug-1559004-EMLINK-handling.t
@@ -6,7 +6,7 @@
cleanup
TESTS_EXPECTED_IN_LOOP=30
-SCRIPT_TIMEOUT=1000
+SCRIPT_TIMEOUT=1200
TEST glusterd
TEST pidof glusterd
diff --git a/tests/include.rc b/tests/include.rc
index 5a99e027df8..5692754563a 100644
--- a/tests/include.rc
+++ b/tests/include.rc
@@ -71,7 +71,7 @@ esac
DEBUG=${DEBUG:=0} # turn on debugging?
PROCESS_DOWN_TIMEOUT=5
-PROCESS_UP_TIMEOUT=30
+PROCESS_UP_TIMEOUT=45
NFS_EXPORT_TIMEOUT=20
CHILD_UP_TIMEOUT=20
PROBE_TIMEOUT=60
diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c
index 323b8340d87..6f6b4cf8aed 100644
--- a/xlators/mgmt/glusterd/src/glusterd-handler.c
+++ b/xlators/mgmt/glusterd/src/glusterd-handler.c
@@ -6031,6 +6031,14 @@ glusterd_mark_bricks_stopped_by_proc (glusterd_brick_proc_t *brick_proc) {
glusterd_set_brick_status (brickinfo_tmp,
GF_BRICK_STOPPED);
brickinfo_tmp->start_triggered = _gf_false;
+ /* When bricks are stopped, ports also need to
+ * be cleaned up
+ */
+ pmap_registry_remove (THIS, brickinfo_tmp->port,
+ brickinfo_tmp->path,
+ GF_PMAP_PORT_BRICKSERVER,
+ NULL, _gf_true);
+
}
}
}
diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.c b/xlators/mgmt/glusterd/src/glusterd-utils.c
index 88aea178028..22c23df131e 100644
--- a/xlators/mgmt/glusterd/src/glusterd-utils.c
+++ b/xlators/mgmt/glusterd/src/glusterd-utils.c
@@ -2508,6 +2508,17 @@ glusterd_volume_stop_glusterfs (glusterd_volinfo_t *volinfo,
if (op_errstr) {
GF_FREE (op_errstr);
}
+ if (is_brick_mx_enabled ()) {
+ /* In case of brick multiplexing we need to make
+ * sure the port is cleaned up from here as the
+ * RPC connection may not have been originated
+ * for the same brick instance
+ */
+ pmap_registry_remove (THIS, brickinfo->port,
+ brickinfo->path,
+ GF_PMAP_PORT_BRICKSERVER,
+ NULL, _gf_true);
+ }
}
(void) glusterd_brick_disconnect (brickinfo);