Whamcloud - gitweb
b=21079
[fs/lustre-release.git] / lustre / tests / runmultiop_bg_pause
1 #!/bin/bash
2
3 # Run multiop in the background, but wait for it to print
4 # "PAUSING" to its stdout before returning from this function.
5
6 PTLDEBUG=${PTLDEBUG:--1}
7 LUSTRE=${LUSTRE:-`dirname $0`/..}
8 . $LUSTRE/tests/test-framework.sh
9
10 TMP=${TMP:-/tmp}
11 MULTIOP_PID_FILE=${MULTIOP_PID_FILE:-$TMP/multiop_bg.pid}
12 rm -f $MULTIOP_PID_FILE
13
14 multiop_bg_pause $*
15 rc=$?
16 [ "$rc" = 0 ] && echo $! > $MULTIOP_PID_FILE
17 exit $rc