From 250bd4736688d9e302cdd02eda1bbe4f68d4ebb6 Mon Sep 17 00:00:00 2001 From: Xicheng Chang Date: Wed, 6 Jul 2016 20:39:59 -0400 Subject: [PATCH] update install.sh and confs Change-Id: Ic7f0bb6f1bfd1b2a7dbfe0c90c85f929b1f907f5 --- install/compass.sh | 38 +++++++++++++++++++------------------- install/install.conf | 2 +- install/install.sh | 4 ++-- install/register.sh | 8 +++++--- 4 files changed, 27 insertions(+), 25 deletions(-) diff --git a/install/compass.sh b/install/compass.sh index 0ecfafd2..f420dc35 100755 --- a/install/compass.sh +++ b/install/compass.sh @@ -129,13 +129,13 @@ else echo "compassed service is refreshed" fi -sudo systemctl status httpd.service -if [[ "$?" != "0" ]]; then - echo "httpd is not started" - exit 1 -else - echo "httpd has already started" -fi +# sudo systemctl status httpd.service +# if [[ "$?" != "0" ]]; then +# echo "httpd is not started" +# exit 1 +# else +# echo "httpd has already started" +# fi sudo systemctl status redis.service |grep running if [[ "$?" != "0" ]]; then @@ -145,11 +145,11 @@ else echo "redis has already started" fi -sudo systemctl status mysql.service |grep running -if [[ "$?" != "0" ]]; then - echo "mysqld is not started" - exit 1 -fi +# sudo systemctl status mysql.service |grep running +# if [[ "$?" != "0" ]]; then +# echo "mysqld is not started" +# exit 1 +# fi sudo systemctl status compass-celeryd.service |grep running if [[ "$?" != "0" ]]; then @@ -159,13 +159,13 @@ else echo "compass-celeryd has already started" fi -sudo systemctl status compass-progress-updated.service |grep running -if [[ "$?" != "0" ]]; then - echo "compass-progress-updated is not started" - exit 1 -else - echo "compass-progress-updated has already started" -fi +# sudo systemctl status compass-progress-updated.service |grep running +# if [[ "$?" != "0" ]]; then +# echo "compass-progress-updated is not started" +# exit 1 +#else +# echo "compass-progress-updated has already started" +#fi sleep 10 #compass check diff --git a/install/install.conf b/install/install.conf index fdae9918..30d09ad7 100755 --- a/install/install.conf +++ b/install/install.conf @@ -41,7 +41,7 @@ export OPTION_ROUTER="10.1.0.15" export IP_START="10.1.0.100" export IP_END="10.1.0.200" # TFTP server's IP address(Default: Management Interface/eth0 IP) -export NEXTSERVER="10.1.10.15" +export NEXTSERVER="10.1.0.15" # The machines MAC list. it must be filled, any space or null is wrong in quotes: export switch_IP="127.0.0.1" diff --git a/install/install.sh b/install/install.sh index 8118b1d6..029dab1b 100755 --- a/install/install.sh +++ b/install/install.sh @@ -88,7 +88,7 @@ set_iptables() sudo rpm -qa | grep iptables-services if [ $? -ne 0 ]; then - sudo yum --enablerepo=compass_install --nogpgcheck -y install iptables-services + sudo yum -y install iptables-services fi sudo /bin/systemctl status iptables.service @@ -220,7 +220,7 @@ done yum update -y sudo rpm -qa | grep net-tools if [ $? -ne 0 ];then - yum --enablerepo=compass_install --nogpgcheck -y install net-tools + yum -y install net-tools fi # check the correct format of ip variables diff --git a/install/register.sh b/install/register.sh index c3b95747..4db968c3 100755 --- a/install/register.sh +++ b/install/register.sh @@ -16,6 +16,8 @@ exit 1 fi echo "Register suceeded, your password is $password, please remember your password at all times." -sed -i 's/^CELERY_DEFAULT_QUEUE.*/CELERY_DEFAULT_QUEUE = '"${USER_EMAIL}"'/g' /etc/compass/celeryconfig -sed -i 's/^CELERY_DEFAULT_EXCHANGE.*/CELERY_DEFAULT_EXCHANGE = '"${USER_EMAIL}"'/g' /etc/compass/celeryconfig -sed -i 's/^CELERY_DEFAULT_ROUTING_KEY.*/CELERY_DEFAULT_ROUTING_KEY = '"${USER_EMAIL}"'/g' /etc/compass/celeryconfig +sed -i 's/^CELERY_DEFAULT_QUEUE.*/CELERY_DEFAULT_QUEUE = \"'"${USER_EMAIL}"'\"/g' /etc/compass/celeryconfig +sed -i 's/^CELERY_DEFAULT_EXCHANGE.*/CELERY_DEFAULT_EXCHANGE = \"'"${USER_EMAIL}"'\"/g' /etc/compass/celeryconfig +sed -i 's/^CELERY_DEFAULT_ROUTING_KEY.*/CELERY_DEFAULT_ROUTING_KEY = \"'"${USER_EMAIL}"'\"/g' /etc/compass/celeryconfig + +systemctl restart compass-celeryd.service