|
|
14f8ab |
From 066189add979d2e4c74463592e5021bd060d5a51 Mon Sep 17 00:00:00 2001
|
|
|
14f8ab |
From: Mohammed Rafi KC <rkavunga@redhat.com>
|
|
|
14f8ab |
Date: Thu, 11 Jul 2019 12:46:47 +0530
|
|
|
14f8ab |
Subject: [PATCH 241/255] Revert "glusterd/svc: glusterd_svcs_stop should call
|
|
|
14f8ab |
individual wrapper function"
|
|
|
14f8ab |
|
|
|
14f8ab |
This reverts commit 79fff98f9ca5f815cf0227312b9a997d555dad29.
|
|
|
14f8ab |
|
|
|
14f8ab |
BUG: 1471742
|
|
|
14f8ab |
Change-Id: I258040ed9be6bc3b4498c76ed51d59258c55acff
|
|
|
14f8ab |
Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
|
|
|
14f8ab |
Reviewed-on: https://code.engineering.redhat.com/gerrit/175950
|
|
|
14f8ab |
Tested-by: RHGS Build Bot <nigelb@redhat.com>
|
|
|
14f8ab |
Reviewed-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
|
|
|
14f8ab |
---
|
|
|
14f8ab |
xlators/mgmt/glusterd/src/glusterd-shd-svc.c | 12 ++----------
|
|
|
14f8ab |
xlators/mgmt/glusterd/src/glusterd-svc-helper.c | 10 +++++-----
|
|
|
14f8ab |
2 files changed, 7 insertions(+), 15 deletions(-)
|
|
|
14f8ab |
|
|
|
14f8ab |
diff --git a/xlators/mgmt/glusterd/src/glusterd-shd-svc.c b/xlators/mgmt/glusterd/src/glusterd-shd-svc.c
|
|
|
14f8ab |
index 981cc87..75f9a07 100644
|
|
|
14f8ab |
--- a/xlators/mgmt/glusterd/src/glusterd-shd-svc.c
|
|
|
14f8ab |
+++ b/xlators/mgmt/glusterd/src/glusterd-shd-svc.c
|
|
|
14f8ab |
@@ -656,18 +656,10 @@ glusterd_shdsvc_stop(glusterd_svc_t *svc, int sig)
|
|
|
14f8ab |
int pid = -1;
|
|
|
14f8ab |
|
|
|
14f8ab |
conf = THIS->private;
|
|
|
14f8ab |
- GF_VALIDATE_OR_GOTO("glusterd", conf, out);
|
|
|
14f8ab |
GF_VALIDATE_OR_GOTO("glusterd", svc, out);
|
|
|
14f8ab |
svc_proc = svc->svc_proc;
|
|
|
14f8ab |
- if (!svc_proc) {
|
|
|
14f8ab |
- /*
|
|
|
14f8ab |
- * This can happen when stop was called on a volume that is not shd
|
|
|
14f8ab |
- * compatible.
|
|
|
14f8ab |
- */
|
|
|
14f8ab |
- gf_msg_debug("glusterd", 0, "svc_proc is null, ie shd already stopped");
|
|
|
14f8ab |
- ret = 0;
|
|
|
14f8ab |
- goto out;
|
|
|
14f8ab |
- }
|
|
|
14f8ab |
+ GF_VALIDATE_OR_GOTO("glusterd", svc_proc, out);
|
|
|
14f8ab |
+ GF_VALIDATE_OR_GOTO("glusterd", conf, out);
|
|
|
14f8ab |
|
|
|
14f8ab |
/* Get volinfo->shd from svc object */
|
|
|
14f8ab |
shd = cds_list_entry(svc, glusterd_shdsvc_t, svc);
|
|
|
14f8ab |
diff --git a/xlators/mgmt/glusterd/src/glusterd-svc-helper.c b/xlators/mgmt/glusterd/src/glusterd-svc-helper.c
|
|
|
14f8ab |
index 6a3ca52..f7be394 100644
|
|
|
14f8ab |
--- a/xlators/mgmt/glusterd/src/glusterd-svc-helper.c
|
|
|
14f8ab |
+++ b/xlators/mgmt/glusterd/src/glusterd-svc-helper.c
|
|
|
14f8ab |
@@ -86,25 +86,25 @@ glusterd_svcs_stop(glusterd_volinfo_t *volinfo)
|
|
|
14f8ab |
priv = this->private;
|
|
|
14f8ab |
GF_ASSERT(priv);
|
|
|
14f8ab |
|
|
|
14f8ab |
- ret = priv->nfs_svc.stop(&(priv->nfs_svc), SIGKILL);
|
|
|
14f8ab |
+ ret = glusterd_svc_stop(&(priv->nfs_svc), SIGKILL);
|
|
|
14f8ab |
if (ret)
|
|
|
14f8ab |
goto out;
|
|
|
14f8ab |
|
|
|
14f8ab |
- ret = priv->quotad_svc.stop(&(priv->quotad_svc), SIGTERM);
|
|
|
14f8ab |
+ ret = glusterd_svc_stop(&(priv->quotad_svc), SIGTERM);
|
|
|
14f8ab |
if (ret)
|
|
|
14f8ab |
goto out;
|
|
|
14f8ab |
|
|
|
14f8ab |
if (volinfo) {
|
|
|
14f8ab |
- ret = volinfo->shd.svc.stop(&(volinfo->shd.svc), SIGTERM);
|
|
|
14f8ab |
+ ret = glusterd_svc_stop(&(volinfo->shd.svc), PROC_START_NO_WAIT);
|
|
|
14f8ab |
if (ret)
|
|
|
14f8ab |
goto out;
|
|
|
14f8ab |
}
|
|
|
14f8ab |
|
|
|
14f8ab |
- ret = priv->bitd_svc.stop(&(priv->bitd_svc), SIGTERM);
|
|
|
14f8ab |
+ ret = glusterd_svc_stop(&(priv->bitd_svc), SIGTERM);
|
|
|
14f8ab |
if (ret)
|
|
|
14f8ab |
goto out;
|
|
|
14f8ab |
|
|
|
14f8ab |
- ret = priv->scrub_svc.stop(&(priv->scrub_svc), SIGTERM);
|
|
|
14f8ab |
+ ret = glusterd_svc_stop(&(priv->scrub_svc), SIGTERM);
|
|
|
14f8ab |
out:
|
|
|
14f8ab |
return ret;
|
|
|
14f8ab |
}
|
|
|
14f8ab |
--
|
|
|
14f8ab |
1.8.3.1
|
|
|
14f8ab |
|