HBASE-4982 graceful_stop.sh does not pass on the --config its passed to its internal invocations of other hbase scripts

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1212050 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Stack 2011-12-08 19:19:45 +00:00
parent badf636b13
commit 685762a691
1 changed files with 9 additions and 9 deletions

View File

@ -70,32 +70,32 @@ hostname=$1
filename="/tmp/$hostname" filename="/tmp/$hostname"
# Run the region mover script. # Run the region mover script.
echo "Disabling balancer!" echo "Disabling balancer!"
echo 'balance_switch false' | "$bin"/hbase shell echo 'balance_switch false' | "$bin"/hbase --config ${HBASE_CONF_DIR} shell
echo "Unloading $hostname region(s)" echo "Unloading $hostname region(s)"
HBASE_NOEXEC=true "$bin"/hbase org.jruby.Main "$bin"/region_mover.rb --file=$filename $debug unload $hostname HBASE_NOEXEC=true "$bin"/hbase --config ${HBASE_CONF_DIR} org.jruby.Main "$bin"/region_mover.rb --file=$filename $debug unload $hostname
echo "Unloaded $hostname region(s)" echo "Unloaded $hostname region(s)"
# Stop the server. Have to put hostname into its own little file for hbase-daemons.sh # Stop the server. Have to put hostname into its own little file for hbase-daemons.sh
hosts="/tmp/$(basename $0).$$.tmp" hosts="/tmp/$(basename $0).$$.tmp"
echo $hostname >> $hosts echo $hostname >> $hosts
if [ "$thrift" != "" ]; then if [ "$thrift" != "" ]; then
"$bin"/hbase-daemons.sh --hosts ${hosts} stop thrift "$bin"/hbase-daemons.sh --config ${HBASE_CONF_DIR} --hosts ${hosts} stop thrift
fi fi
if [ "$rest" != "" ]; then if [ "$rest" != "" ]; then
"$bin"/hbase-daemons.sh --hosts ${hosts} stop rest "$bin"/hbase-daemons.sh --config ${HBASE_CONF_DIR} --hosts ${hosts} stop rest
fi fi
"$bin"/hbase-daemons.sh --hosts ${hosts} stop regionserver "$bin"/hbase-daemons.sh --config ${HBASE_CONF_DIR} --hosts ${hosts} stop regionserver
if [ "$restart" != "" ]; then if [ "$restart" != "" ]; then
"$bin"/hbase-daemons.sh --hosts ${hosts} start regionserver "$bin"/hbase-daemons.sh --config ${HBASE_CONF_DIR} --hosts ${hosts} start regionserver
if [ "$thrift" != "" ]; then if [ "$thrift" != "" ]; then
# -b 0.0.0.0 says listen on all interfaces rather than just default. # -b 0.0.0.0 says listen on all interfaces rather than just default.
"$bin"/hbase-daemons.sh --hosts ${hosts} start thrift -b 0.0.0.0 "$bin"/hbase-daemons.sh --config ${HBASE_CONF_DIR} --hosts ${hosts} start thrift -b 0.0.0.0
fi fi
if [ "$rest" != "" ]; then if [ "$rest" != "" ]; then
"$bin"/hbase-daemons.sh --hosts ${hosts} start rest "$bin"/hbase-daemons.sh --config ${HBASE_CONF_DIR} --hosts ${hosts} start rest
fi fi
if [ "$reload" != "" ]; then if [ "$reload" != "" ]; then
echo "Reloading $hostname region(s)" echo "Reloading $hostname region(s)"
HBASE_NOEXEC=true "$bin"/hbase org.jruby.Main "$bin"/region_mover.rb --file=$filename $debug load $hostname HBASE_NOEXEC=true "$bin"/hbase --config ${HBASE_CONF_DIR} org.jruby.Main "$bin"/region_mover.rb --file=$filename $debug load $hostname
echo "Reloaded $hostname region(s)" echo "Reloaded $hostname region(s)"
fi fi
fi fi