From: Victor H. <xca...@so...> - 2015-07-02 18:43:58
|
The branch, master has been updated via 5a56f8e7205ff67b5853dd88fd85043ee2758ff7 (commit) via bfd69e98242ca9b39ac78678e4fc4abd0b9c4194 (commit) from 7c70f2c3d1905fd75f8fed410915e0c02628aafb (commit) ----------------------------------------------------------------------- commit 5a56f8e7205ff67b5853dd88fd85043ee2758ff7 Merge: bfd69e9 7c70f2c Author: Victor Hu <vh...@us...> Date: Thu Jul 2 14:43:40 2015 -0400 Merge branch 'master' of ssh://git.code.sf.net/p/xcat/xcat-core commit bfd69e98242ca9b39ac78678e4fc4abd0b9c4194 Author: Victor Hu <vh...@us...> Date: Thu Jul 2 14:41:43 2015 -0400 If conserver and confluent are running at the same time, rcons will say "Connection closed." Add a check in the rcons code to make sure that if confluent is configured to be used, conserver is not running and vice versa. ----------------------------------------------------------------------- diff --git a/xCAT-client/bin/rcons b/xCAT-client/bin/rcons index 21f204e..40f9195 100755 --- a/xCAT-client/bin/rcons +++ b/xCAT-client/bin/rcons @@ -65,7 +65,12 @@ if [ "$CONSOLE_SERVICE_KEYWORD" == "consoleservice" ]; then fi if [ $USE_CONFLUENT == "1" ] && ([ -x "/opt/confluent/bin/confetty" ] || [ -x "/usr/bin/confetty" ] || [ -x "/usr/local/bin/confetty" ]); then - #use confluent + # use confluent, make sure conserver is not also running + CONSERVER_RC=`service conserver status >> /dev/null; echo $?` + if [[ ${CONSERVER_RC} == 0 ]]; then + echo "Error: consoleservice is set to 'confluent' but conserver is running. Stop conserver, run makeconfluentcfg, and retry..." + exit 1 + fi CONFETTY="confetty" if [ -x "/opt/confluent/bin/confetty" ]; then CONFETTY="/opt/confluent/bin/confetty" @@ -92,7 +97,13 @@ if [ $USE_CONFLUENT == "1" ] && ([ -x "/opt/confluent/bin/confetty" ] || [ -x "/ fi $CONFETTY $CONSCONTROLPATH $CONSERVER $1 elif [ -f "/usr/bin/console" ] || [ -f "/bin/console" ]; then - #use conserver + # use conserver, make sure confluent is not also running + CONFLUENT_RC=`service confluent status >> /dev/null; echo $?` + if [[ ${CONFLUENT_RC} == 0 ]]; then + echo "Error: consoleservice is set to 'conserver' but confluent is running. Stop confluent, run makeconservercf, and retry..." + exit 1 + fi + if [ -z "$CONSERVER" ]; then CONSERVER=`nodels $1 nodehm.conserver 2>/dev/null | awk -F: '{print $2}' | tr -d ' '` fi |