Whamcloud - gitweb
LU-9260 test: Use the correct mount device when test against lustre 61/28661/4
authorWei Liu <wei3.liu@intel.com>
Wed, 23 Aug 2017 16:49:29 +0000 (09:49 -0700)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 13 Sep 2017 03:37:09 +0000 (03:37 +0000)
The changes pass the MGSNID:/FSNAME into test, instead of
using the default loop device when testing against lustre.
The corresponding changes to the Posix test suites are also needed
to make the testing pass. Related changes apply to toolkit.

Test-Parameters: trivial testlist=posix

Change-Id: I32fc5a401fdc53ed133a78dc4c84b4a7e2a5ad19
Signed-off-by: Wei Liu <wei3.liu@intel.com>
Reviewed-on: https://review.whamcloud.com/28661
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/posix.sh
lustre/tests/posix/posix.cfg

index 4c36a9a..429b93d 100755 (executable)
@@ -137,7 +137,7 @@ test_1() {
        fi
 
        log "Run POSIX test against lustre filesystem"
-       run_posix $MOUNT compare || \
+       run_posix $MOUNT $MGSNID $FSNAME compare ||
                error_noexit "Run POSIX testsuite on $MOUNT failed"
 
        [[ -d "$MOUNT/TESTROOT" ]] && rm -fr $MOUNT/TESTROOT
index 4cb72e3..13fcebd 100644 (file)
@@ -168,25 +168,28 @@ cleanup() {
 }
 
 run_posix() {
-    local MNTPNT=$1
-    local COMPARE=${2}
-    local compare=""
-    local rc=0
-    local cmd
-
-    [[ "x$COMPARE" != "x" ]] && compare="--compare-result"
-    # command to run posix test suite
-    cmd="TMP=/tmp/vsx0 TMPDIR=/tmp/vsx0 $POSIX_RUN --mountpt=$MNTPNT \
-        --posix-src=$POSIX_SRC --install-dir=$INSTALL_DIR \
-        --results-dir=$RESULT_DIR $compare 2>&1"
-
-    # run posix test suite
-    echo $cmd
-    if ! eval $cmd; then
-        rc=${PIPESTATUS[0]}
-    fi
+       local MNTPNT=$1
+       local MGSNID=$2
+       local FSNAME=$3
+       local COMPARE=${4}
+       local compare=""
+       local rc=0
+       local cmd
+
+       [[ "x$COMPARE" != "x" ]] && compare="--compare-result"
+       # command to run posix test suite
+       cmd="TMP=/tmp/vsx0 TMPDIR=/tmp/vsx0 $POSIX_RUN --mountpt=$MNTPNT \
+               --posix-src=$POSIX_SRC --install-dir=$INSTALL_DIR \
+               --results-dir=$RESULT_DIR --nospc-dev="$MGSNID:/$FSNAME" \
+               $compare 2>&1"
+
+       # run posix test suite
+       echo $cmd
+       if ! eval $cmd; then
+               rc=${PIPESTATUS[0]}
+       fi
 
-    return $rc
+       return $rc
 }
 
 setup_posix() {