4 # Exercises unwritten extent reads and writes, looking
5 # for data corruption (zeroes read) near the end of file.
7 #-----------------------------------------------------------------------
8 # Copyright (c) 2000-2004 Silicon Graphics, Inc. All Rights Reserved.
9 #-----------------------------------------------------------------------
15 echo "QA output created by $seq"
19 status=1 # failure is the default!
20 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
22 # get standard environment, filters and checks
28 sed -e "s,$TEST_DIR/resv,[TESTFILE],g" \
29 -e 's/[0-9][0-9]* bytes/NUM bytes/g'
32 pgsize=`$here/src/feature -s`
34 # -i == number of iterations
35 # -l == bytes to leak on each iteration
36 # -b == read/write block size
37 # -s == preallocation size
39 # real QA test starts here
41 _supported_os IRIX Linux
43 if [ $HOSTOS == "IRIX" ]; then
44 if uname -R | grep -iq debug; then
45 # taking up to 23 mins on my 512K octane on debug
46 # not worth worrying about
47 _notrun "don't bother running on debug IRIX"
52 echo "*** First case - I/O blocksize same as pagesize"
53 $here/src/resvtest -i 20 -b $pgsize "$TEST_DIR/resv" | _filter_resv
54 [ $? -eq 0 ] && echo done
55 rm -f "$TEST_DIR/mumble"
58 echo "*** Second case - 512 byte I/O blocksize"
59 $here/src/resvtest -i 40 -b 512 "$TEST_DIR/resv" | _filter_resv
60 [ $? -eq 0 ] && echo done
61 rm -f "$TEST_DIR/grumble"