Port of ORI-620 to the master
it can be hard to write 1MB in a second for some
backends (like ZFS), so relax current synchronous
semantics as this doesn't affect the logic.
Signed-off-by: Alex Zhuravlev <bzzz@whamcloud.com>
Signed-off-by: Mikhail Pershin <tappro@whamcloud.com>
Change-Id: Ie87815de4a2ae51fc166287d74d43278101fe76b
Reviewed-on: http://review.whamcloud.com/4212
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
run_test 79 "df report consistency check ======================="
test_80() { # bug 10718
+ # relax strong synchronous semantics for slow backends like ZFS
+ local soc="obdfilter.*.sync_on_lock_cancel"
+ local soc_old=$(do_facet ost1 lctl get_param -n $soc | head -n1)
+ local hosts=
+ if [ "$soc_old" != "never" -a "$FSTYPE" != "ldiskfs" ]; then
+ hosts=$(for host in $(seq -f "ost%g" 1 $OSTCOUNT); do
+ facet_active_host $host; done | sort -u)
+ do_nodes $hosts lctl set_param $soc=never
+ fi
+
dd if=/dev/zero of=$DIR/$tfile bs=1M count=1 seek=1M
sync; sleep 1; sync
local BEFORE=`date +%s`
if [ $DIFF -gt 1 ] ; then
error "elapsed for 1M@1T = $DIFF"
fi
+
+ [ -n "$hosts" ] && do_nodes $hosts lctl set_param $soc=$soc_old
+
true
rm -f $DIR/$tfile
}