Skip to content

Instantly share code, notes, and snippets.

@hoto
Created May 30, 2017 13:36
Show Gist options
  • Save hoto/b40611c14c81373f211b6138232bc75f to your computer and use it in GitHub Desktop.
Save hoto/b40611c14c81373f211b6138232bc75f to your computer and use it in GitHub Desktop.
show memory on all coreos hosts
for ip in $(fleetctl list-machines | cut -f 2); \
do ssh core@$ip bash -c "hostname && free -mh | head -n 2"; \
done | grep -E "worker|\$"
@hoto
Copy link
Author

hoto commented May 30, 2017

for ip in $(fleetctl list-machines | grep worker | cut -f 2); \
do ssh core@$ip bash -c "hostname && free -mh | head -n 2"; \
done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment