diff options
author | Britney Fransen <brfransen@gmail.com> | 2015-03-05 01:10:11 (GMT) |
---|---|---|
committer | Britney Fransen <brfransen@gmail.com> | 2015-03-05 01:10:11 (GMT) |
commit | 4fa58e575df074c999db5cbc13a2488131597fcc (patch) | |
tree | 8c020858d8b9516b4f6e881cf8310ed8a489350e /abs/core/xymon/xymon-smart.sh | |
parent | 53d9a174f4f05c94c0fe392a83deb310095310b1 (diff) | |
download | linhes_pkgbuild-4fa58e575df074c999db5cbc13a2488131597fcc.zip linhes_pkgbuild-4fa58e575df074c999db5cbc13a2488131597fcc.tar.gz linhes_pkgbuild-4fa58e575df074c999db5cbc13a2488131597fcc.tar.bz2 |
xymon: add hddtemp module
Diffstat (limited to 'abs/core/xymon/xymon-smart.sh')
-rwxr-xr-x | abs/core/xymon/xymon-smart.sh | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/abs/core/xymon/xymon-smart.sh b/abs/core/xymon/xymon-smart.sh index 1ad3cc7..f951158 100755 --- a/abs/core/xymon/xymon-smart.sh +++ b/abs/core/xymon/xymon-smart.sh @@ -4,15 +4,13 @@ if test -f /tmp/dres; then rm -f /tmp/dres; fi -# MODIFY below to match your setup - the "scsi-SATA" is pretty generic, but you -# can add more disks if you like. E.g. I have a USB disk permanently plugged in. - -ls /dev/disk/by-id/scsi-* /dev/disk/by-id/ata-* /dev/disk/by-id/usb-* | grep -v -- -part | sort | +ls /dev/disk/by-id/* | grep -ve '-part' -ve '/wwn-' | while read DISK do DISKDEV=`ls -l $DISK | awk -F/ '{print $NF}'` #check if disk is removable + RM=0 RM=`cat /sys/block/$DISKDEV/removable` if test $RM -ne 0 then @@ -62,4 +60,3 @@ $XYMON $XYMSRV "status ${MACHINE}.smart ${COLOR} SMART Health Check rm -f /tmp/dres /tmp/dcheck exit 0 - |