fix: minor improvement to parsing disk space

main
Francesco Minnocci 11 months ago
parent 1bf04d9872
commit 55b0af1d33
No known key found for this signature in database
GPG Key ID: 76DA3AF9BAED1A32

@ -1,6 +1,6 @@
#!/bin/bash
# Returns used and free disk space of all machines in the cluster
# Example output: steffe8 9.2G 47G
# 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 $3" "$4}'\'')'
parallel --nonall --slf /home/rock/macchine.txt 'echo $HOSTNAME $(df -Ph | grep mmcblk0p5 | awk '\''{print $2" "$3}'\'' | sed '\''s/G//g'\'')'

Loading…
Cancel
Save