STAT_BEFORE=`stat -c "a: %x m: %y c: %z" $1`
$DEFRAG_PROG -v $1 >> $seqres.full 2>&1
- _scratch_remount
+ _scratch_cycle_mount
STAT_AFTER=`stat -c "a: %x m: %y c: %z" $1`
[ ! -z $csum ] && CSUM_AFTER=`md5sum $1`
esac
}
-_scratch_remount()
+_scratch_cycle_mount()
{
_scratch_unmount
_scratch_mount
echo "Setting subvol to the default"
subvolid=$(_btrfs_get_subvolid $SCRATCH_MNT subvol)
$BTRFS_UTIL_PROG subvolume set-default $subvolid $SCRATCH_MNT | _filter_scratch
-_scratch_remount
+_scratch_cycle_mount
echo "List root dir which is now subvol"
ls $SCRATCH_MNT
_scratch_unmount
ls $SCRATCH_MNT
echo "Setting the root dir as the default again"
$BTRFS_UTIL_PROG subvolume set-default 0 $SCRATCH_MNT | _filter_scratch
-_scratch_remount
+_scratch_cycle_mount
echo "List root dir"
ls $SCRATCH_MNT
$BTRFS_UTIL_PROG subvolume delete $SCRATCH_MNT/snap | _filter_btrfs_subvol_delete
echo "List root dir"
ls $SCRATCH_MNT
-_scratch_remount
+_scratch_cycle_mount
echo "List root dir"
ls $SCRATCH_MNT
fi
fi
ret_val=$?
- _scratch_remount
+ _scratch_cycle_mount
# Older defrag returned "20" for success
# e9393c2 btrfs-progs: defrag return zero on success
if [ $ret_val -ne 0 -a $ret_val -ne 20 ]; then
echo "File digests before remounting the file system:"
md5sum $SCRATCH_MNT/foo | _filter_scratch
md5sum $SCRATCH_MNT/bar | _filter_scratch
-_scratch_remount
+_scratch_cycle_mount
echo "File digests after remounting the file system:"
md5sum $SCRATCH_MNT/foo | _filter_scratch
md5sum $SCRATCH_MNT/bar | _filter_scratch
# Check that after defragmenting the file and re-mounting, the file
# content remains exactly the same as before.
_run_btrfs_util_prog filesystem defragment $SCRATCH_MNT/foo
- _scratch_remount
+ _scratch_cycle_mount
od -t x1 $SCRATCH_MNT/foo | _filter_od
# Verify that there are no consistency errors.
# Validate the content of bar still matches foo's content even after
# clearing all of bar's data from the page cache.
-_scratch_remount
+_scratch_cycle_mount
echo "Verifying target file digest after umount + mount"
md5sum $SCRATCH_MNT/bar | _filter_scratch
# We expect to be able to mount the fs again and have available all metadata and
# data that got persisted in the first transaction.
-_scratch_remount
+_scratch_cycle_mount
# We now expect file's foo content to match what it had when the first
# transaction was committed because the second transaction was aborted and we
# object was marked as full when initialized (because it had 0 total bytes),
# which prevented the file write path from attempting to allocate a data block
# group and fail immediately with ENOSPC.
-_scratch_remount
+_scratch_cycle_mount
echo "hello world" > $SCRATCH_MNT/foobar
echo "Silence is golden"
# exclusively in the read path). The issue happened only if the same
# readpages() call targeted pages belonging to the first and second
# ranges that point to the same compressed extent.
- _scratch_remount
+ _scratch_cycle_mount
echo "File contents after mounting filesystem again:"
# Must match the same contents we got before.
_run_btrfs_util_prog quota rescan -w $SCRATCH_MNT
# Remount to clear cache, force everything to disk
-_scratch_remount
+_scratch_cycle_mount
# Finally, delete snap1 to trigger btrfs_drop_snapshot(). This
# snapshot is most interesting to delete because it will cause some
# bug exclusively in the read path of compressed extents, the correct
# data was stored on disk, btrfs just failed to fill in the pages
# correctly.
- _scratch_remount
+ _scratch_cycle_mount
echo "File contents after remount:"
# Must match the digest we got before.
echo "==== check data contents ===="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
hexdump -C $testfile
rm $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
echo "==== Pre-Remount ==="
hexdump -C $testfile
-_scratch_remount
+_scratch_cycle_mount
echo "==== Post-Remount =="
hexdump -C $testfile
wait
# clear page cache and dump the file
-_scratch_remount
+_scratch_cycle_mount
hexdump $SCRATCH_MNT/file
status=0
$XFS_IO_PROG -c "fzero -k $i 4k" $file >> $seqres.full 2>&1
done
-_scratch_remount
+_scratch_cycle_mount
hexdump $file
status=0
# Now ummount and mount again the fs. After this we expect the file's size to
# be 512Kb.
-_scratch_remount
+_scratch_cycle_mount
# Now check that all data we wrote before are available and the file size is
# 512Kb.
# up being written to disk.
$XFS_IO_PROG -c "truncate 160K" $SCRATCH_MNT/foo
-_scratch_remount
+_scratch_cycle_mount
# We expect to see a file with a size of 160Kb, with the first 128Kb of data all
# having the value 0xaa and the remaining 32Kb of data all having the value 0x00
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2
-_scratch_remount
+_scratch_cycle_mount
echo "Delete while rewriting"
rm -rf $testdir/file1 &
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
overwrite() {
while [ ! -e $testdir/finished ]; do
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
overwrite() {
while [ ! -e $testdir/finished ]; do
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_pwrite_byte 0x62 0 $((loops * blksz)) $testdir/file2 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file3
-_scratch_remount
+_scratch_cycle_mount
fbytes() {
egrep -v '(61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61|62 62 62 62 62 62 62 62 62 62 62 62 62 62 62 62)'
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_pwrite_byte 0x62 0 $((loops * blksz)) $testdir/file2 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file3
-_scratch_remount
+_scratch_cycle_mount
fbytes() {
egrep -v '(61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61|62 62 62 62 62 62 62 62 62 62 62 62 62 62 62 62)'
echo "Initialize file"
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
# Snapshot creator...
snappy() {
echo "Initialize file"
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
# Snapshot creator...
snappy() {
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_pwrite_byte 0x62 0 $((loops * blksz)) $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
# Direct I/O overwriter...
overwrite() {
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
_pwrite_byte 0x62 0 $((loops * blksz)) $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
# Direct I/O overwriter...
overwrite() {
echo ${out}
echo "Remount and try CoW again"
-_scratch_remount
+_scratch_cycle_mount
out="$(_pwrite_byte 0x62 0 $((blksz * nr_blks)) $testdir/bigfile 2>&1)"
echo ${out} | grep -q "No space left on device" || echo "CoW should have failed with ENOSPC"
echo ${out}
echo "Remount and try CoW again"
-_scratch_remount
+_scratch_cycle_mount
out="$(_pwrite_byte 0x62 0 $((blksz * nr_blks)) $testdir/bigfile 2>&1)"
echo ${out} | grep -q "No space left on device" || echo "CoW should have failed with ENOSPC"
fi
echo "Remount and try CoW again"
-_scratch_remount
+_scratch_cycle_mount
out="$(_mwrite_byte 0x62 0 $((blksz * nr_blks)) $((blksz * nr_blks)) $testdir/bigfile 2>&1)"
err="$?"
echo ${out}
echo "Remount and try CoW again"
-_scratch_remount
+_scratch_cycle_mount
out="$(_pwrite_byte 0x62 0 $((blksz * nr_blks)) $testdir/bigfile -d 2>&1)"
echo ${out} | grep -q "No space left on device" || echo "CoW should have failed with ENOSPC"
n=$(( (2 ** i) * blksz))
_reflink_range "$testdir/file1" 0 "$testdir/file1" $n $n >> "$seqres.full"
done
-_scratch_remount
+_scratch_cycle_mount
echo "Reflink the big file"
blks=$((2 ** (fnr + 1) ))
echo "punching..." >> "$seqres.full"
"$here/src/punch-alternating" "$testdir/file1" >> "$seqres.full"
echo "...done" >> "$seqres.full"
-_scratch_remount
+_scratch_cycle_mount
echo "Reflink the big file"
bytes=$((blocks_needed * blksz))
_reflink_range $testdir/file2 $((blksz * f)) $testdir/file3 $((blksz * f)) $blksz >> $seqres.full
_pwrite_byte 0x62 $((blksz * f)) $blksz $testdir/file3.chk >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_reflink_range $testdir/file2 $((blksz * f)) $testdir/file3 $((blksz * f)) $blksz >> $seqres.full
_pwrite_byte 0x62 $((blksz * f)) $blksz $testdir/file3.chk >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_reflink_range $testdir/file2 $((blksz * f)) $testdir/file3 $((blksz * f)) $blksz >> $seqres.full
_pwrite_byte 0x62 $((blksz * f)) $blksz $testdir/file3.chk >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
_fragment_freesp $testdir/bigfile >> $seqres.full 2>&1
filesize=$((blksz * nr))
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_reflink_range $testdir/file2 $((blksz * f)) $testdir/file3 $((blksz * f)) $blksz >> $seqres.full
_pwrite_byte 0x62 $((blksz * f)) $blksz $testdir/file3.chk >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
_fragment_freesp $testdir/bigfile >> $seqres.full 2>&1
filesize=$((blksz * nr))
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_weave_reflink_holes_delalloc $blksz $nr $testdir/file3 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_weave_reflink_holes_delalloc $blksz $nr $testdir/file3 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_rainbow $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
# now cow
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_weave_reflink_rainbow $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
# now cow
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_reflink_range $testdir/file1 $((blksz * f)) $testdir/file3 $((blksz * f)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * f)) $blksz $testdir/file3.chk >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $((blksz + 17)) $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2
_pwrite_byte 0x61 0 $((blksz + 17)) $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) 17" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) 17" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $((blksz + 17)) $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2
_pwrite_byte 0x61 0 $((blksz + 17)) $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 $blksz $blksz" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $blksz $blksz" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
echo "CoW and unmount"
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
echo "CoW and unmount"
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
echo "CoW and unmount"
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $testdir/file1 $blksz $testdir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || _fail "file1 and file2 don't match."
_reflink_range $dir/file1 $blksz $dir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $dir/file2.chk >> $seqres.full
- _scratch_remount
+ _scratch_cycle_mount
echo "Compare files"
! cmp -s $dir/file1 $dir/file2 || _fail "file1 and file2 don't match."
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $dir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $((blksz + 17)) $((blksz * 3 - 34))" $dir/file2.chk >> $seqres.full
- _scratch_remount
+ _scratch_cycle_mount
echo "Compare files"
! cmp -s $dir/file1 $dir/file2 || _fail "file1 and file2 don't match."
_reflink_range $dir/file1 $blksz $dir/file2 $((blksz * 2)) $blksz >> $seqres.full
_pwrite_byte 0x61 $((blksz * 2)) $blksz $dir/file2.chk >> $seqres.full
- _scratch_remount
+ _scratch_cycle_mount
echo "Compare files"
! cmp -s $dir/file1 $dir/file2 || _fail "file1 and file2 don't match."
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $dir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 $blksz $((blksz * 3))" $dir/file2.chk >> $seqres.full
- _scratch_remount
+ _scratch_cycle_mount
echo "Compare files"
! cmp -s $dir/file1 $dir/file2 || _fail "file1 and file2 don't match."
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $filesize $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 2)) $blksz $((blksz * 2))" -c "truncate $((blksz * 2))" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 2)) $blksz $((blksz * 2))" -c "truncate $((blksz * 2))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $filesize $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" -c "fpunch $((blksz * 2)) $blksz" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" -c "pwrite -S 0x00 $((blksz * 2)) $blksz" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $filesize $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" -c "fzero $((blksz * 2)) $blksz" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" -c "pwrite -S 0x00 $((blksz * 2)) $blksz" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $filesize $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" -c "fcollapse $((blksz * 2)) $blksz" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 2)) $blksz $((blksz * 2))" -c "truncate $((blksz * (nr - 1)))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $filesize $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 2)) $blksz $((blksz * 2))" -c "finsert $((blksz * 2)) $blksz" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
_pwrite_byte 0x62 $blksz $blksz $testdir/file2.chk >> $seqres.full
_pwrite_byte 0x00 $((blksz * 2)) $blksz $testdir/file2.chk >> $seqres.full
_pwrite_byte 0x62 $((blksz * 3)) $blksz $testdir/file2.chk >> $seqres.full
_pwrite_byte 0x61 $((blksz * 4)) $blksz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $filesize $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" -c "falloc $((blksz * 2)) $blksz" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -f -c "pwrite -S 0x62 -b $((blksz * 3)) $blksz $((blksz * 3))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_scratch_mount
touch $SCRATCH_MNT/tmp
-_scratch_remount
+_scratch_cycle_mount
ctime1=`stat -c %z $SCRATCH_MNT/tmp`
sleep 1
chattr -A $SCRATCH_MNT/tmp
ctime2=`stat -c %z $SCRATCH_MNT/tmp`
-_scratch_remount
+_scratch_cycle_mount
ctime3=`stat -c %z $SCRATCH_MNT/tmp`
if [ "$ctime1" == "$ctime2" ]; then
nr=64
filesize=$((blksz * nr))
_sweave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_sweave_reflink_holes_delalloc $blksz $nr $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
nr=64
filesize=$((blksz * nr))
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_sweave_reflink_holes_delalloc $blksz $nr $testdir/file1 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $real_blksz 0 $((filesize + 1))" -c "fdatasync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $real_blksz 0 $((filesize + 1))" -c "fdatasync" $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Create the original files"
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
for i in `seq 1 8`; do
$XFS_IO_PROG -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" -c "fdatasync" $testdir/file2 >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Create the original files"
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
for i in `seq 1 8`; do
$XFS_IO_PROG -d -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" $testdir/file2 >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
touch $testdir/erk
chown fsgqa $testdir/erk
_repquota
-_scratch_remount
+_scratch_cycle_mount
echo "Change file ownership"
chown fsgqa $testdir/file1
_repquota
echo "Remount the FS to see if accounting changes"
-_scratch_remount
+_scratch_cycle_mount
_repquota
echo "Chown one of the files"
_scratch_mount >/dev/null 2>&1
touch $testfile
-_scratch_remount
+_scratch_cycle_mount
ctime1=`stat -c %Z $testfile`
sleep 1
setfacl -m 'u::x,g::x,o::x' $testfile
ctime2=`stat -c %Z $testfile`
-_scratch_remount
+_scratch_cycle_mount
ctime3=`stat -c %Z $testfile`
if [ "$ctime1" == "$ctime2" ]; then
touch $testdir/erk
chown fsgqa $testdir/erk
_repquota
-_scratch_remount
+_scratch_cycle_mount
echo "Change file ownership"
chown fsgqa $testdir/file1
_repquota
echo "Remount the FS to see if accounting changes"
-_scratch_remount
+_scratch_cycle_mount
_repquota
echo "Chown one of the files"
chown fsgqa $testdir/file1
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_repquota
-_scratch_remount
+_scratch_cycle_mount
echo "Set hard quota to prevent third reflink"
setquota -u fsgqa 0 1024 0 0 $SCRATCH_MNT
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file3 >> $seqres.full
_repquota
-_scratch_remount
+_scratch_cycle_mount
echo "Set hard quota to prevent rewrite"
setquota -u fsgqa 0 1024 0 0 $SCRATCH_MNT
echo "Create the original files"
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
sync
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $TEST_DIR/moo >> $seqres.full
$AIO_TEST -f DIRECT -b $bufsize $TEST_DIR/moo $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Create the original files"
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $TEST_DIR/moo >> $seqres.full
sync
$AIO_TEST -b $bufsize $TEST_DIR/moo $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Initialize file"
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
# Snapshot creator...
snappy() {
echo "Initialize file"
echo > $seqres.full
_pwrite_byte 0x61 0 $((loops * blksz)) $testdir/file1 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
# Snapshot creator...
snappy() {
echo "Grow fs"
$XFS_GROWFS_PROG $SCRATCH_MNT 2>&1 | _filter_growfs >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Create more reflink copies"
_cp_reflink $testdir/original $testdir/copy3
nr=$((sz / blksz))
_pwrite_byte 0x61 0 $sz $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "CoW every other block"
_pwrite_byte 0x62 0 $sz $testdir/file1 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_pwrite_byte 0x61 0 $sz $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
_pwrite_byte 0x61 0 $sz $testdir/file2.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
cmp -s $testdir/file1 $testdir/file2 || echo "file1 and file2 do not match"
_pwrite_byte 0x62 $((f * blksz)) $blksz $testdir/file2 >> $seqres.full
_pwrite_byte 0x62 $((f * blksz)) $blksz $testdir/file2.chk >> $seqres.full
done
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
! cmp -s $testdir/file1 $testdir/file2 || echo "file1 and file2 must not match"
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" -c "fdatasync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $real_blksz 0 $((filesize + 1))" -c "fdatasync" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $((filesize + 1))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $real_blksz 0 $((filesize + 1))" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $((filesize + 1))" -c "fdatasync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "falloc 0 $((filesize + 1))" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "falloc 0 $filesize" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" -c "fdatasync" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "CoW and unmount"
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" -c "fdatasync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "fadvise -d 0 $filesize" -c "fsync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "falloc 0 $filesize" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -d -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" -c "fdatasync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "fadvise -d 0 $filesize" -c "fsync" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "falloc 0 $filesize" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 0 0" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 0 1048576" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 0 0" $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Set extsz and cowextsz on zero byte file"
$XFS_IO_PROG -c "extsize 1048576" $testdir/file1 | _filter_scratch
echo "Set extsz and cowextsz on 1Mbyte file"
$XFS_IO_PROG -c "extsize 1048576" $testdir/file2 | _filter_scratch
$XFS_IO_PROG -c "cowextsize 1048576" $testdir/file2 | _filter_scratch
-_scratch_remount
+_scratch_cycle_mount
echo "Check extsz and cowextsz settings on zero byte file"
$XFS_IO_PROG -c "extsize" $testdir/file1 | _filter_scratch
echo "Set cowextsize and check flag"
$XFS_IO_PROG -c "cowextsize 1048576" $testdir/file3 | _filter_scratch
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -c "stat" $testdir/file3 | grep 'fsxattr.xflags' | _filter_scratch
$XFS_IO_PROG -c "cowextsize" $testdir/file3 | _filter_scratch
echo "Unset cowextsize and check flag"
$XFS_IO_PROG -c "cowextsize 0" $testdir/file3 | _filter_scratch
-_scratch_remount
+_scratch_cycle_mount
$XFS_IO_PROG -c "stat" $testdir/file3 | grep 'fsxattr.xflags' | _filter_scratch
$XFS_IO_PROG -c "cowextsize" $testdir/file3 | _filter_scratch
$XFS_IO_PROG -f -c "extsize $bufsize" $testdir/file3
$XFS_IO_PROG -f -c "cowextsize $real_blksz" $testdir/file3
_cp_reflink $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $filesize" -c "fdatasync" $testdir/file3 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $real_blksz 0 $((filesize + 1))" -c "fdatasync" $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
touch "$testdir/dir-$nr/file-$nnr"
done
done
-_scratch_remount
+_scratch_cycle_mount
echo "Check cowextsize settings"
seq 1 2 | while read nr; do
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $((filesize + 1))" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "cowextsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "cowextsize" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -R -S 0x63 -b $real_blksz 0 $((filesize + 1))" $testdir/file2 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b 8388608 0 $filesize" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
$XFS_IO_PROG -f -c "extsize $bufsize" $testdir/file2
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Crash and recover"
$XFS_IO_PROG -x -c "shutdown" $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
touch $testdir/erk
chown fsgqa $testdir/erk
_repquota
-_scratch_remount
+_scratch_cycle_mount
echo "Change file ownership"
chown fsgqa $testdir/file1
_repquota
echo "Remount the FS to see if accounting changes"
-_scratch_remount
+_scratch_cycle_mount
_repquota
echo "Chown one of the files"
touch $testdir/erk
chown fsgqa $testdir/erk
_repquota
-_scratch_remount
+_scratch_cycle_mount
echo "Change file ownership"
chown fsgqa $testdir/file1
_repquota
echo "Remount the FS to see if accounting changes"
-_scratch_remount
+_scratch_cycle_mount
_repquota
echo "Chown one of the files"
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_weave_reflink_holes_delalloc $blksz $nr $testdir/file3 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_weave_reflink_holes_delalloc $blksz $nr $testdir/file3 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_rainbow $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
# now cow
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
internal_blks=$((filesize / real_blksz))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_weave_reflink_rainbow $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
# now cow
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file3 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file3.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file2.chk >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Grow fs"
$XFS_GROWFS_PROG $SCRATCH_MNT 2>&1 | _filter_growfs >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Create more copies"
cp -p $testdir/original $testdir/copy3
$XFS_IO_PROG -c "cowextsize $((bufsize * 2))" $testdir
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
sync
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $TEST_DIR/moo >> $seqres.full
$AIO_TEST -f DIRECT -b $bufsize $TEST_DIR/moo $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -c "cowextsize $((bufsize * 2))" $testdir
$XFS_IO_PROG -f -c "pwrite -S 0x61 -b $bufsize 0 $filesize" $testdir/file1 >> $seqres.full
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $bufsize 0 $filesize" $TEST_DIR/moo >> $seqres.full
sync
$AIO_TEST -b $bufsize $TEST_DIR/moo $testdir/file2 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
test $(_xfs_bmapx_find data $testdir/file3 '000000$') -gt 0 || \
echo "Expected to find a regular data extent"
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
echo "Create the original files"
$XFS_IO_PROG -f -c "falloc 0 256k" -c "pwrite 252k 6k" $testdir/file1 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
_cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
echo "Compare files"
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
cowsz=$((filesize / 2))
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_sweave_reflink_holes_delalloc $blksz $nr $testdir/file1 >> $seqres.full
$XFS_IO_PROG -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
filesize=$((blksz * nr))
$XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
_sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch
_sweave_reflink_holes_delalloc $blksz $nr $testdir/file1 >> $seqres.full
$XFS_IO_PROG -d -f -c "pwrite -S 0x63 -b $cowsz $cowoff $cowsz" $testdir/file1 >> $seqres.full
_pwrite_byte 0x63 $cowoff $cowsz $testdir/file1.chk >> $seqres.full
-_scratch_remount
+_scratch_cycle_mount
echo "Compare files"
md5sum $testdir/file1 | _filter_scratch