diff --git a/scripts/disk-usage b/scripts/disk-usage index 1af78a4..f5139c8 100755 --- a/scripts/disk-usage +++ b/scripts/disk-usage @@ -2,4 +2,4 @@ DEVICE="$1" -df | grep "$DEVICE" | tr -s ' ' | cut -d' ' -f 2-3 | tr ' ' '\n' +df "$DEVICE" | tail -n 1 | tr -s ' ' | cut -d' ' -f 2-3 | tr ' ' '\n' diff --git a/scripts/raid-status b/scripts/raid-status index bd0f4c4..ffa7ca9 100755 --- a/scripts/raid-status +++ b/scripts/raid-status @@ -1,6 +1,6 @@ #!/bin/sh -DEVICE="/dev/md0" +DEVICE="$1" TOTAL_DEVICES=$(mdadm -D "$DEVICE" | grep 'Total Devices' | cut -d':' -f 2 | tr -d ' ')