#! /bin/sh
# XFS QA Test No. 049
-# $Id: 1.1 $
#
# XFS on loop test
#
#-----------------------------------------------------------------------
-# Copyright (c) 2000 Silicon Graphics, Inc. All Rights Reserved.
+# Copyright (c) 2000-2002 Silicon Graphics, Inc. All Rights Reserved.
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of version 2 of the GNU General Public License as
_require_scratch
_require_loop
+[ "$USE_EXTERNAL" = yes ] && _notrun "Test doesn't cope with external devices"
+
rm -f $seq.full
echo "(dev=$SCRATCH_DEV, mount=$SCRATCH_MNT)" >> $seq.full
|| _fail "!!! failed to mount"
_log "Create xfs fs in file on scratch"
-mkfs -t xfs -d file,name=$SCRATCH_MNT/test.xfs,size=20m >> $seq.full 2>&1 \
+/sbin/mkfs.xfs -f $MKFS_OPTIONS -dfile,name=$SCRATCH_MNT/test.xfs,size=40m \
+ >> $seq.full 2>&1 \
|| _fail "!!! failed to mkfs xfs"
_log "Make mount points"
|| _fail "!!! failed to loop mount xfs"
_log "stress"
-src/fsstress -d $SCRATCH_MNT/test -n 1000 $FSSTRESS_AVOID >> $seq.full 2>&1 \
+ltp/fsstress -d $SCRATCH_MNT/test -n 1000 $FSSTRESS_AVOID >> $seq.full 2>&1 \
|| _fail "!!! stress failed"
_log "clean"
|| _fail "!!! failed to loop mount xfs"
_log "stress ext2 on xfs via loop"
-src/fsstress -d $SCRATCH_MNT/test2 -n 1000 $FSSTRESS_AVOID >> $seq.full 2>&1 \
+ltp/fsstress -d $SCRATCH_MNT/test2 -n 1000 $FSSTRESS_AVOID >> $seq.full 2>&1 \
|| _fail "!!! stress ext2 failed"
_log "clean"