Update cluster-withdraw
This commit is contained in:
parent
8f03967d84
commit
d0e19aac90
@ -17,7 +17,6 @@ WORKER_LIST="worker.list"
|
|||||||
#FIXME Write usage message
|
#FIXME Write usage message
|
||||||
function usage {
|
function usage {
|
||||||
cat << EOF
|
cat << EOF
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -28,14 +27,20 @@ function echo_err {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
## Check files from parameters
|
## Check file from parameters
|
||||||
if [ ! -f $WORKER_LIST ]; then
|
if [ ! -f $WORKER_LIST ]; then
|
||||||
echo_err "Worker list file ($WORKER_LIST) not exists."
|
echo_err "Worker list file ($WORKER_LIST) not exists."
|
||||||
exit 1
|
exit 1
|
||||||
else if [ ! -s $WORKER_LIST ]; then
|
fi
|
||||||
|
|
||||||
|
## Check the file contents
|
||||||
|
if [ ! -s $WORKER_LIST ]; then
|
||||||
echo_err "Worker list file ($WORKER_LIST) is empty."
|
echo_err "Worker list file ($WORKER_LIST) is empty."
|
||||||
|
exit 1
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
|
## Create WORKER array from file
|
||||||
|
readarray WORKER < $WORKER_LIST
|
||||||
|
|
||||||
# Reset Master node
|
# Reset Master node
|
||||||
./withdraw/node_reset.sh
|
./withdraw/node_reset.sh
|
||||||
|
Loading…
Reference in New Issue
Block a user