Print this page
7290 ZFS test suite needs to control what utilities it can run
Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>

*** 23,33 **** # # Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # ! # Copyright (c) 2013 by Delphix. All rights reserved. # . $STF_SUITE/include/libtest.shlib . $STF_SUITE/tests/functional/inheritance/inherit.kshlib --- 23,33 ---- # # Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # ! # Copyright (c) 2013, 2016 by Delphix. All rights reserved. # . $STF_SUITE/include/libtest.shlib . $STF_SUITE/tests/functional/inheritance/inherit.kshlib
*** 56,69 **** typeset disks=$3 if [[ $type == "POOL" ]]; then create_pool "$dataset" "$disks" elif [[ $type == "CTR" ]]; then ! log_must $ZFS create $dataset ! log_must $ZFS set canmount=off $dataset elif [[ $type == "FS" ]]; then ! log_must $ZFS create $dataset else log_fail "Unrecognised type $type" fi list="$list $dataset" --- 56,69 ---- typeset disks=$3 if [[ $type == "POOL" ]]; then create_pool "$dataset" "$disks" elif [[ $type == "CTR" ]]; then ! log_must zfs create $dataset ! log_must zfs set canmount=off $dataset elif [[ $type == "FS" ]]; then ! log_must zfs create $dataset else log_fail "Unrecognised type $type" fi list="$list $dataset"
*** 141,151 **** record_val=`get_prop recordsize $dataset` if [[ $init_code == "-" || $init_code == "default" ]]; then def_val[idx]=$record_val def_recordsize=1 elif [[ $init_code == "local" ]]; then ! log_must $ZFS set recordsize=$record_val $dataset local_val[idx]=$record_val fi } # --- 141,151 ---- record_val=`get_prop recordsize $dataset` if [[ $init_code == "-" || $init_code == "default" ]]; then def_val[idx]=$record_val def_recordsize=1 elif [[ $init_code == "local" ]]; then ! log_must zfs set recordsize=$record_val $dataset local_val[idx]=$record_val fi } #
*** 330,346 **** # if [[ $op == "-" ]]; then log_note "No operation specified" else export __ZFS_POOL_RESTRICT="$TESTPOOL" ! log_must $ZFS unmount -a unset __ZFS_POOL_RESTRICT for p in ${prop[i]} ${prop[((i+1))]}; do ! $ZFS $op $p $target ret=$? ! check_failure $ret "$ZFS $op $p \ $target" done fi for check_obj in $list; do read init_src final_src --- 330,346 ---- # if [[ $op == "-" ]]; then log_note "No operation specified" else export __ZFS_POOL_RESTRICT="$TESTPOOL" ! log_must zfs unmount -a unset __ZFS_POOL_RESTRICT for p in ${prop[i]} ${prop[((i+1))]}; do ! zfs $op $p $target ret=$? ! check_failure $ret "zfs $op $p \ $target" done fi for check_obj in $list; do read init_src final_src