From 96f7cc1216729783ddee5acee25bdc67b7323176 Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Tue, 5 Jan 2016 10:39:55 +0100 Subject: [hardware-stats] Log /dev path of HDD for each smartctl --- .../hardware-stats/data/opt/openslx/scripts/systemd-hardware_stats | 1 + 1 file changed, 1 insertion(+) (limited to 'remote') diff --git a/remote/modules/hardware-stats/data/opt/openslx/scripts/systemd-hardware_stats b/remote/modules/hardware-stats/data/opt/openslx/scripts/systemd-hardware_stats index 8de902b3..2b54e3e7 100755 --- a/remote/modules/hardware-stats/data/opt/openslx/scripts/systemd-hardware_stats +++ b/remote/modules/hardware-stats/data/opt/openslx/scripts/systemd-hardware_stats @@ -108,6 +108,7 @@ if which smartctl; then for dev in $(fdisk -l | grep -o '^Disk /dev/\S*:' | cut -c 6-); do dev=${dev:0:-1} smartctl -i -H -A -f "brief" "$dev" > "$FILE" || continue + echo "NEXTHDD=$dev" >> "$ALLSMART" cat "$FILE" >> "$ALLSMART" # parse OVERALL=$(grep -o "test result: .*$" "$FILE" | cut -c 14-) -- cgit v1.2.3-55-g7522