Add GPL license plate to SGI's test files.
[xfstests-dev.git] / 119
1 #! /bin/sh
2 #
3 #-----------------------------------------------------------------------
4 # Copyright (c) 2000-2005 Silicon Graphics, Inc.  All Rights Reserved.
5 #
6 # This program is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU General Public License as
8 # published by the Free Software Foundation.
9 #
10 # This program is distributed in the hope that it would be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 # GNU General Public License for more details.
14 #
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write the Free Software Foundation,
17 # Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
18 #
19 #-----------------------------------------------------------------------
20 #
21 # FS QA Test No. 119
22 #
23 # Leaking reservation space in the GRH
24 # Test out pv#942130
25 # This can hang when things aren't working
26 #
27 # creator
28 owner=tes@crackle.melbourne.sgi.com
29
30 seq=`basename $0`
31 echo "QA output created by $seq"
32
33 here=`pwd`
34 tmp=/tmp/$$
35 status=1        # failure is the default!
36 trap "_cleanup; exit \$status" 0 1 2 3 15
37
38 _cleanup()
39 {
40     cd /
41     rm -f $tmp.*
42 }
43
44 # get standard environment, filters and checks
45 . ./common.rc
46 . ./common.filter
47
48 # real QA test starts here
49
50 # Modify as appropriate.
51 _supported_fs xfs
52 _supported_os IRIX Linux
53
54 _require_scratch
55
56 # this may hang
57 sync
58
59 export MKFS_OPTIONS="-l version=2,size=1200b,su=64k" 
60 export MOUNT_OPTIONS="-o logbsize=64k"
61 _scratch_mkfs_xfs >/dev/null
62
63 _scratch_mount
64
65 max=99
66 i=0
67 echo "start freezing and unfreezing"
68 while [ $i -lt $max ]; do
69         xfs_freeze -f $SCRATCH_MNT
70         xfs_freeze -u $SCRATCH_MNT
71         echo -n .
72         let i=$i+1
73 done
74 echo "done"
75
76 # success, all done
77 status=0
78 exit