8 Commits

Author SHA1 Message Date
Gaurav Kumar Garg
220d406ad1 glusterd: Gluster should keep PID file in correct location
Currently Gluster keeps process pid information of all the daemons
and brick processes in Gluster configuration file directory
(ie., /var/lib/glusterd/*).

These pid files should be seperate from configuration files.
Deletion of the configuration file directory might result into serious problems.
Also, /var/run/gluster is the default placeholder directory for pid files.

So, with this fix Gluster will keep all process pid information of all
processes in /var/run/gluster/* directory.

Change-Id: Idb09e3fccb6a7355fbac1df31082637c8d7ab5b4
BUG: 1258561
Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com>
Signed-off-by: Saravanakumar Arumugam <sarumuga@redhat.com>
Reviewed-on: https://review.gluster.org/13580
Tested-by: MOHIT AGRAWAL <moagrawa@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.org>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
2017-08-11 07:36:41 +00:00
Prasanna Kumar Kalever
87303b77dd extras: kill gsyncd before glusterfsd
It's a good practice to kill gsyncd before brick process, else we see
unnecessary loops and logs of bring up the faulty bricks

Change-Id: I2d2176f2bf5014f3afd622194a8b2d60c86926af
BUG: 1367771
Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
Reviewed-on: http://review.gluster.org/15187
Tested-by: Prasanna Kumar Kalever <pkalever@redhat.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Smoke: Gluster Build System <jenkins@build.gluster.org>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
Reviewed-by: Kotresh HR <khiremat@redhat.com>
2016-08-29 04:55:15 -07:00
Prasanna Kumar Kalever
14b46be09c extras: kill processes gracefully
Currently all of brick, gsyncd and other glustershd services/processes
are killed without checking for ongoing tasks such as geo-rep,
self-heal, rebalance and etc. which may lead to inconsistency after
the node is brought back.

This patch introduce an option '-g' which ensures whether all the
gluster processes are ready (not busy) to be terminated before we
executing 'kill' on them

Usage: ./extras/stop-all-gluster-processes.sh [-g] [-h]
    options:
    -g  Terminate in graceful mode
    -h  Show this message, then exit

 eg:
  1. ./extras/stop-all-gluster-processes.sh
  2. ./extras/stop-all-gluster-processes.sh -g

By default, this script executes in force mode, processes are killed
without checking for ongoing tasks, on specifying '-g' option this
script works in graceful mode, which returns exitcode if some of gluster
processes are busy in doing their jobs.

exitcodes include:
   0       No errors/Success
   64      Rebalance is in progress
   65      Self-Heal is in progress
   66      Tier daemon running on this node
   127     option not found

Change-Id: I2f924b2bf9f04a81788d0f5604895a42755b33a1
BUG: 1367771
Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
Reviewed-on: http://review.gluster.org/15188
Tested-by: Prasanna Kumar Kalever <pkalever@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.org>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Reviewed-by: Rajesh Joseph <rjoseph@redhat.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-by: mohammed rafi  kc <rkavunga@redhat.com>
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
2016-08-29 04:54:49 -07:00
Kaleb S KEITHLEY
2df72780e4 scripts: bash-isms in scripts
Change-Id: I05f8718fb73c16dbb37c1f7460bb7b55cc0ffe97
BUG: 1336853
Reported-by: Patrick Matthäi <pmatthaei@debian.org>
Signed-off-by: Kaleb S KEITHLEY <kkeithle@redhat.com>
Reviewed-on: http://review.gluster.org/14401
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kotresh HR <khiremat@redhat.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.com>
2016-05-18 02:22:35 -07:00
Prasanna Kumar Kalever
48608e2ca1 extras: stop all include glusterfs process as well
currently, extras/stop-all-gluster-processes.sh script handles
brick processes, node services and geo-rep's gsync process.

from now this script also handles mount processes as well,
as part of this patch I have reorganized this script

Change-Id: Id62d6fda6dd331bde722ce3d99ec3f09fed55cb0
BUG: 1334620
Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
Reviewed-on: http://review.gluster.org/14277
Tested-by: Prasanna Kumar Kalever <pkalever@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.com>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.com>
2016-05-13 15:07:10 -07:00
Shubhendu Tripathi
066a45d760 extras: Exit with SUCCESS if no processes to stop
This script might be executed even when there are no
valid processes running to be stopped. In this scenario,
the script should return with SUCCESS

Change-Id: Ia293214a4b5052bc4bef9769f197f7b05c55ffe9
BUG: 1277533
Signed-off-by: Shubhendu Tripathi <shtripat@redhat.com>
Reviewed-on: http://review.gluster.org/11739
Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
2015-11-10 00:56:57 -08:00
Kotresh HR
85865daa1b extras: Fix stop-all-gluster-processes.sh script
"test -n" command takes single string as argument. The
command was failing with "Too many arguments" when multiple
pids are got.

Change-Id: Icc409082f492c72522168d5e203684f00f52cf1b
BUG: 1204641
Signed-off-by: Kotresh HR <khiremat@redhat.com>
Reviewed-on: http://review.gluster.org/9970
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2015-04-06 10:44:35 -07:00
Amar Tumballi
d65e8a871a extras: add a script to stop all the glusterfs process
Change-Id: I9f73bf0308625695ed78db06478963d16644852a
Signed-off-by: Amar Tumballi <amarts@redhat.com>
Reviewed-on: http://review.gluster.org/6270
Reviewed-by: Sachidananda Urs <sacchi@gmail.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-06-17 04:37:21 -07:00