Skip to content

Commit

Permalink
try setting tunable
Browse files Browse the repository at this point in the history
  • Loading branch information
pcd1193182 committed Aug 13, 2019
1 parent 03305a6 commit fbbf33f
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions tests/zfs-tests/tests/functional/refquota/refquota_008_neg.ksh
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,19 @@

verify_runnable "both"

oldvalue=$(get_tunable spa_asize_inflation)
function cleanup
{
set_tunable32 spa_asize_inflation $oldvalue
log_must zfs destroy -rf $TESTPOOL/$TESTFS
log_must zfs create $TESTPOOL/$TESTFS
log_must zfs set mountpoint=$TESTDIR $TESTPOOL/$TESTFS
}

log_onexit cleanup

set_tunable32 spa_asize_inflation 2

TESTFILE='testfile'
FS=$TESTPOOL/$TESTFS
log_must zfs create $FS/$TESTSUBFS1
Expand All @@ -56,11 +60,11 @@ log_must zfs create $FS/$TESTSUBFS2
mntpnt1=$(get_prop mountpoint $FS/$TESTSUBFS1)
mntpnt2=$(get_prop mountpoint $FS/$TESTSUBFS2)

log_must mkfile 800M $mntpnt1/$TESTFILE
log_must zfs snapshot $FS/$TESTSUBFS1@snap800m
log_must mkfile 200M $mntpnt1/$TESTFILE
log_must zfs snapshot $FS/$TESTSUBFS1@snap200m

log_must zfs set refquota=10M $FS/$TESTSUBFS2
log_mustnot eval "zfs send $FS/$TESTSUBFS1@snap800m |" \
log_mustnot eval "zfs send $FS/$TESTSUBFS1@snap200m |" \
"zfs receive -F $FS/$TESTSUBFS2"

log_pass "ZFS receive does not override refquota"
Expand Down

0 comments on commit fbbf33f

Please sign in to comment.