hw-test/scripts/test-badblocks

22 lines
331 B
Text
Raw Normal View History

2016-12-14 20:26:15 -06:00
#!/bin/bash
2016-12-14 22:57:46 -06:00
if [[ -z $OUTPUT_DIR ]] ; then
source scan-dmidecode
fi
if [[ ! -f $OUTPUT_DIR/disk.lst ]] ; then
scan-hdd
fi
for DISK in `cat $OUTPUT_DIR/disk.lst \
| sed 's/#.*$//' \
| cut -d ':' -f 1`
do
SERIAL=`cat $OUTPUT_DIR/disk.lst \
| grep $DISK \
| cut -d ':' -f 2`
wrapper-badblocks $DISK $SERISL
done
2016-12-14 20:26:15 -06:00