--- tags: Program --- # clusterinfo.sh(叢集系統資訊檢視) ```bash= #!/bin/bash source config [ `hostname` != "${HN}" ] && echo "wrong hostname" && exit 1 [ `whoami` != "${UR}" ] && echo "wrong user" && exit 1 [ `pwd` != ${DR} ] && echo "pls move to cnt2" && exit 1 for n in ${CLUSTER} do nc -w 1 -z $n 22 &>/dev/null if [ "$?" == "0" ];then ssh $n "curl -s http://${IP}:${HTTPORT}/sysinfo.sh | bash" fi done ```
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up