fstests: convert remaining tests to SPDX license tags
[xfstests-dev.git] / tests / xfs / 043
1 #! /bin/bash
2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2000-2002 Silicon Graphics, Inc.  All Rights Reserved.
4 #
5 # FS QA Test No. 043
6 #
7 # Test out xfsdump/restore but rmv inventory prior to restore.
8 # This checks that the on-disk inventory can be successfully
9 # rebuilt from the on-tape inventory.
10 #
11 seqfull=$0
12 seq=`basename $0`
13 seqres=$RESULT_DIR/$seq
14 echo "QA output created by $seq"
15
16 here=`pwd`
17 tmp=/tmp/$$
18 status=1        # failure is the default!
19 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
20
21 # get standard environment, filters and checks
22 . ./common/rc
23 . ./common/dump
24
25 # real QA test starts here
26 _supported_fs xfs
27 _supported_os Linux
28
29 _require_tape $TAPE_DEV 
30 _create_dumpdir_fill
31 _erase_hard
32 _do_dump_sub
33 rm -rf /var/{,lib/}xfsdump/inventory # delete it - let cleanup fix it
34 _do_restore
35 _diff_compare_sub
36 _ls_compare_sub
37
38 # success, all done
39 status=0
40 exit