3
# Copyright (C) 2010 Karel Zak <kzak@redhat.com>
5
TS_TOPDIR="$(dirname $0)/../.."
8
. $TS_TOPDIR/functions.sh
11
TESTPROG="$TS_HELPER_LIBMOUNT_LOCK"
13
[ -x $TESTPROG ] || ts_skip "test not compiled"
16
# Be careful with number of processes. Don't forget that there is time limit
17
# when the mount waits on the mtab lock. If you define too much processes some
18
# of them will fail with timeout.
20
# Note: the original version (< 2.13) of util-linux is completely useless for
21
# this test (maximum for this old version is NLOOPS=10 and NPROCESSES=5 (2-way
22
# 2GHz machine)). It has terrible performance due a bad timeouts implemntation
31
SYNCTIME=$(( $(date +%s) + 5 ))
33
for id in $(seq 0 $(( $NPROCESSES - 1 ))); do
34
$TESTPROG --lock --synctime $SYNCTIME $TS_OUTPUT $NLOOPS >> $TS_OUTPUT.debug 2>&1 &