forked from phc/cluster-dashboard
Compare commits
4 Commits
Author | SHA1 | Date |
---|---|---|
Francesco Minnocci | 23be1a5e2a | 11 months ago |
Francesco Minnocci | 55b0af1d33 | 11 months ago |
Francesco Minnocci | 1bf04d9872 | 11 months ago |
Antonio De Lucreziis | 425cf4d371 | 2 years ago |
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns CPU percentages of all machines in the cluster
|
||||
# Example output: steffe3 3.5
|
||||
|
||||
parallel --nonall --slf /home/rock/macchine.txt 'echo $HOSTNAME $(top -bn1 | grep "Cpu(s)" | sed "s/.*, *\([0-9.]*\)%* id.*/\1/" | sed "s/^/100 - /" | bc)'
|
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns used and total memory (in MB) of all machines in the cluster
|
||||
# Example output: steffe1 141 3814
|
||||
|
||||
parallel --nonall --slf /home/rock/macchine.txt 'echo $HOSTNAME $(free -m | awk '\''/Mem/{print $3" "$2}'\'')'
|
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns received and transmitted bytes of all machines in the cluster
|
||||
# Example output: steffe14 3581663131 3305835017
|
||||
|
||||
parallel --nonall --slf /home/rock/macchine.txt 'echo $HOSTNAME $(cat /sys/class/net/[e]*/statistics/{r,t}x_bytes)'
|
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns total and used disk space (in GB) of all machines in the cluster
|
||||
# Example output: steffe16 8.9 47
|
||||
|
||||
parallel --nonall --slf /home/rock/macchine.txt 'echo $HOSTNAME $(df -Ph | grep mmcblk0p5 | awk '\''{print $2" "$3}'\'' | sed '\''s/G//g'\'')'
|
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns Unix uptime, in seconds, of all machines in the cluster
|
||||
# Example output: steffe1 1656959
|
||||
|
||||
parallel --nonall --slf /home/rock/macchine.txt 'echo $HOSTNAME $(cut -f1 -d. /proc/uptime)'
|
Loading…
Reference in New Issue