#!/bin/bash
user=`whoami`
echo -e "================ 正在关闭 102 103 104 集群 ==========="
for((host=104; host>=102; host--)); do
echo -e "\n---$user@hadoop$host---"
ssh $user@hadoop$host 'sudo shutdown now'
done
#!/bin/bash
user=`whoami`
echo -e "================ 正在关闭 102 103 104 集群 ==========="
for((host=104; host>=102; host--)); do
echo -e "\n---$user@hadoop$host---"
ssh $user@hadoop$host 'sudo shutdown now'
done
本文标题:黑猴子的家:xshutdown.sh
本文链接:https://www.haomeiwen.com/subject/xfiagrtx.html
网友评论