stop_all.sh 889 B

1234567891011121314151617181920212223242526272829303132333435
  1. #!/bin/sh
  2. workDir=`dirname $0`
  3. workDir=`cd ${workDir};pwd`
  4. source $workDir/../conf/config/run_config.conf
  5. source $workDir/../conf/config/install_config.conf
  6. mastersHost=(${masters//,/ })
  7. for master in ${mastersHost[@]}
  8. do
  9. echo $master
  10. ssh $master "cd $installPath/; sh bin/escheduler-daemon.sh stop master-server;"
  11. done
  12. workersHost=(${workers//,/ })
  13. for worker in ${workersHost[@]}
  14. do
  15. echo $worker
  16. ssh $worker "cd $installPath/; sh bin/escheduler-daemon.sh stop worker-server;"
  17. ssh $worker "cd $installPath/; sh bin/escheduler-daemon.sh stop logger-server;"
  18. done
  19. ssh $alertServer "cd $installPath/; sh bin/escheduler-daemon.sh stop alert-server;"
  20. apiServersHost=(${apiServers//,/ })
  21. for apiServer in ${apiServersHost[@]}
  22. do
  23. echo $apiServer
  24. ssh $apiServer "cd $installPath/; sh bin/escheduler-daemon.sh stop api-server;"
  25. done