Whamcloud - gitweb
LU-12579 tests: allow some margin in runtests 11/36011/3
authorAndreas Dilger <adilger@whamcloud.com>
Fri, 30 Aug 2019 23:23:50 +0000 (17:23 -0600)
committerOleg Drokin <green@whamcloud.com>
Mon, 16 Sep 2019 23:05:04 +0000 (23:05 +0000)
Allow some margin in the space used by runtests for internal
log files for Lustre and the underlying filesystem.

Test-Parameters: trivial testlist=runtests,runtests,runtests
Test-Parameters: mdtcount=4 mdscount=2 testlist=runtests,runtests,runtests
Test-Parameters: fstype=zfs testlist=runtests,runtests,runtests
Test-Parameters: fstype=zfs mdtcount=4 mdscount=2 testlist=runtests,runtests
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: I34b47a8436c5718be311698a3f6e6d7af7ea45ad
Reviewed-on: https://review.whamcloud.com/36011
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Nunez <jnunez@whamcloud.com>
Reviewed-by: Patrick Farrell <pfarrell@whamcloud.com>
lustre/tests/runtests

index 51f0353..dd64560 100755 (executable)
@@ -128,7 +128,7 @@ log "done"
 wait_delete_completed
 sleep 5 # let MDS refresh aggregated statfs
 NOWUSED=$(($(df -P $DIR | awk '{ print $3 }' | tail -n 1)))
 wait_delete_completed
 sleep 5 # let MDS refresh aggregated statfs
 NOWUSED=$(($(df -P $DIR | awk '{ print $3 }' | tail -n 1)))
-if [ $(expr $NOWUSED - $USED) -gt 1024 ]; then
+if [ $(expr $NOWUSED - $USED) -gt $(fs_log_size) ]; then
        error "Space not all freed: now ${NOWUSED}kB, was ${USED}kB."
 else
        log "Space was freed: now ${NOWUSED}kB, was ${USED}kB."
        error "Space not all freed: now ${NOWUSED}kB, was ${USED}kB."
 else
        log "Space was freed: now ${NOWUSED}kB, was ${USED}kB."