Last active
August 29, 2015 14:10
-
-
Save m3nd3s/e9e2900aa3e155ef8067 to your computer and use it in GitHub Desktop.
Remote command
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
HOSTS=$(cat <<EOF | |
dev.adena.com.br | |
dev.acimaq.adena.com.br | |
EOF) | |
CMD="ls -lah /proc/\$(pidof java)/task | wc -l" | |
for H in $HOSTS | |
do | |
echo -n "${H}: " | |
ssh adena@$H $CMD | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment