]> git.proxmox.com Git - mirror_zfs.git/commitdiff
Streamline the zpool_import tests
authorTim Chase <tim@chase2k.com>
Fri, 4 May 2018 04:02:38 +0000 (23:02 -0500)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 9 May 2018 04:40:13 +0000 (21:40 -0700)
Don't create an ext4 file system atop $DEV_DISKDIR/$DISK2.
There's likely to not be sufficient space for it to succeed.
Instead, simply create the vdev files in the directory where it
would have been mounted.

Signed-off-by: Tim Chase <tim@chase2k.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #7459

tests/zfs-tests/tests/functional/cli_root/zpool_import/cleanup.ksh
tests/zfs-tests/tests/functional/cli_root/zpool_import/setup.ksh

index f4f317cbecc141cd8e7a428a26992680d7a6ce78..fd67dc7694f194991a1e310ea1894923eb92a560 100755 (executable)
@@ -40,9 +40,6 @@ for pool in "$TESTPOOL" "$TESTPOOL1"; do
        destroy_pool "$pool"
 done
 
-ismounted $DEVICE_DIR $NEWFS_DEFAULT_FS
-(( $? == 0 )) && log_must umount -f $DEVICE_DIR
-
 for dir in "$TESTDIR" "$TESTDIR1" "$DEVICE_DIR" ; do
        [[ -d $dir ]] && \
                log_must rm -rf $dir
index d81e66636d84a7da10d85812b83087b5bfcddef7..9f0ccfb6cb483d9e26e8340284b5189996588a6a 100755 (executable)
@@ -68,16 +68,9 @@ fi
 log_must zfs create $TESTPOOL/$TESTFS
 log_must zfs set mountpoint=$TESTDIR $TESTPOOL/$TESTFS
 
-DISK2="$(echo $DISKS | nawk '{print $2}')"
-echo "y" | newfs -v $DEV_DSKDIR/$DISK2 >/dev/null 2>&1
-(( $? != 0 )) &&
-       log_untested "Unable to setup a $NEWFS_DEFAULT_FS file system"
-
 [[ ! -d $DEVICE_DIR ]] && \
        log_must mkdir -p $DEVICE_DIR
 
-log_must mount $DEV_DSKDIR/$DISK2 $DEVICE_DIR
-
 i=0
 while (( i < $MAX_NUM )); do
        log_must mkfile $FILE_SIZE ${DEVICE_DIR}/${DEVICE_FILE}$i