summaryrefslogtreecommitdiffstats
path: root/rpc
diff options
context:
space:
mode:
authorMohammed Rafi KC <rkavunga@redhat.com>2019-06-24 12:00:20 +0530
committerAtin Mukherjee <amukherj@redhat.com>2019-07-09 12:19:02 +0000
commit670299cf4fc90c1c61032057b6ff570fee7a448e (patch)
treeca28aa959348ff86047607e0bb99a8140e131220 /rpc
parenta94d7433169cbf29b9109c96ac57b99e898e6f17 (diff)
glusterd/svc: update pid of mux volumes from the shd process
For a normal volume, we are updating the pid from a the process while we do a daemonization or at the end of the init if it is no-daemon mode. Along with updating the pid we also lock the file, to make sure that the process is running fine. With brick mux, we were updating the pidfile from gluterd after an attach/detach request. There are two problems with this approach. 1) We are not holding a pidlock for any file other than parent process. 2) There is a chance for possible race conditions with attach/detach. For example, shd start and a volume stop could race. Let's say we are starting an shd and it is attached to a volume. While we trying to link the pid file to the running process, this would have deleted by the thread that doing a volume stop. Change-Id: I29a00352102877ce09ea3f376ca52affceb5cf1a Updates: bz#1722541 Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
Diffstat (limited to 'rpc')
-rw-r--r--rpc/xdr/src/glusterd1-xdr.x1
1 files changed, 1 insertions, 0 deletions
diff --git a/rpc/xdr/src/glusterd1-xdr.x b/rpc/xdr/src/glusterd1-xdr.x
index 9b36d34378a..02ebec26c01 100644
--- a/rpc/xdr/src/glusterd1-xdr.x
+++ b/rpc/xdr/src/glusterd1-xdr.x
@@ -132,6 +132,7 @@ struct gd1_mgmt_brick_op_req {
string name<>;
int op;
opaque input<>;
+ opaque dict<>;
} ;
struct gd1_mgmt_brick_op_rsp {