smart check ignore not present device
This commit is contained in:
parent
5413e7a9a2
commit
510d19a5f8
@ -108,7 +108,7 @@
|
||||
OPT=""
|
||||
udevadm info --query=all -n $disk | grep -q usb- && OPT="-d sat"
|
||||
smartctl -H $OPT $disk >${g_tmp}/smartctl
|
||||
if ! cat ${g_tmp}/smartctl | egrep -iq "SMART overall-health self-assessment test result: PASSED|SMART Health Status: OK"
|
||||
if ! cat ${g_tmp}/smartctl | egrep -iq "SMART overall-health self-assessment test result: PASSED|SMART Health Status: OK|Read Device Identity failed: scsi error no medium present"
|
||||
then
|
||||
g_echo_error "SMART of $disk unhealthy: $(cat ${g_tmp}/smartctl)"
|
||||
fi
|
Loading…
Reference in New Issue
Block a user