echo $test with $threads threads
+ $oprofile opcontrol --start
+
# start up vmstat and record its pid
nice -19 vmstat 1 > $vmstat_log 2>&1 &
[ $? = 0 ] || die "vmstat failed"
iostat_pids[$i]=$pid
done
+ $oprofile opcontrol --reset
+
# start all the tests. each returns a pid to wait on
pids=""
for i in `seq 0 $last_block`; do
pid_has_stopped $pid
done
+ $oprofile opcontrol --shutdown
+ $oprofile opreport > $tmpdir/oprofile
+ echo >> $tmpdir/oprofile
+ $oprofile opreport -c -l | head -20 >> $tmpdir/oprofile
+ save_output $tmpdir/oprofile $opref.oprofile
+
# collect the results of vmstat and iostat
cpu=$(mean_stddev $(awk \
'(NR > 3 && NF == 16 && $16 != "id" ) \
fi
if [ ! -z "$output_dir" ]; then
- [ ! -e "$output_dir" ] && "output dir $output_dir doesn't exist"
- [ ! -d "$output_dir" ] && "output dir $output_dir isn't a directory"
+ [ ! -e "$output_dir" ] && mkdir -p "$output_dir" || die \
+ "error creating $output_dir"
+ [ ! -d "$output_dir" ] && die "$output_dir isn't a directory"
fi
block=`echo $block | sed -e 's/,/ /g'`
fi
done
+if which opcontrol; then
+ echo generating oprofile results
+ oprofile=""
+else
+ echo not using oprofile
+ oprofile=": "
+fi
+
[ $min_threads -gt $max_threads ] && \
die "min threads $min_threads must be <= min_threads $min_threads"
echo "T = number of concurrent threads per device"
echo "L = base io operation length, in KB"
echo "m = IO method: read, write, or over-write"
+ echo "A = aggregate throughput from all devices"
echo "C = percentage CPU used, both user and system"
echo "MB/s = per-device throughput"
echo "rR = read requests issued to the device per second"