Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
LU-8220 tests: stripe file over all active OSTs
[fs/lustre-release.git]
/
lustre
/
tests
/
functions.sh
diff --git
a/lustre/tests/functions.sh
b/lustre/tests/functions.sh
index
8e5a3cd
..
84916b0
100644
(file)
--- a/
lustre/tests/functions.sh
+++ b/
lustre/tests/functions.sh
@@
-194,11
+194,16
@@
mpi_run () {
}
nids_list () {
}
nids_list () {
- local list
- for i in ${1//,/ }; do
- list="$list $i@$NETTYPE"
- done
- echo $list
+ local list
+ local escape="$2"
+ for i in ${1//,/ }; do
+ if [ "$list" = "" ]; then
+ list="$i@$NETTYPE"
+ else
+ list="$list$escape $i@$NETTYPE"
+ fi
+ done
+ echo $list
}
# FIXME: all setup/cleanup can be done without rpc.sh
}
# FIXME: all setup/cleanup can be done without rpc.sh
@@
-284,6
+289,8
@@
run_compilebench() {
# compile dir kernel-0 ~1GB
# required space ~1GB * cbench_IDIRS
# compile dir kernel-0 ~1GB
# required space ~1GB * cbench_IDIRS
+ local dir=${1:-$DIR}
+
cbench_DIR=${cbench_DIR:-""}
cbench_IDIRS=${cbench_IDIRS:-2}
cbench_RUNS=${cbench_RUNS:-2}
cbench_DIR=${cbench_DIR:-""}
cbench_IDIRS=${cbench_IDIRS:-2}
cbench_RUNS=${cbench_RUNS:-2}
@@
-296,7
+303,7
@@
run_compilebench() {
[ -e $cbench_DIR/compilebench ] || \
{ skip_env "No compilebench build" && return; }
[ -e $cbench_DIR/compilebench ] || \
{ skip_env "No compilebench build" && return; }
- local space=$(df -P $
DIR
| tail -n 1 | awk '{ print $4 }')
+ local space=$(df -P $
dir
| tail -n 1 | awk '{ print $4 }')
if [[ $space -le $((1024 * 1024 * cbench_IDIRS)) ]]; then
cbench_IDIRS=$((space / 1024 / 1024))
[[ $cbench_IDIRS -eq 0 ]] &&
if [[ $space -le $((1024 * 1024 * cbench_IDIRS)) ]]; then
cbench_IDIRS=$((space / 1024 / 1024))
[[ $cbench_IDIRS -eq 0 ]] &&
@@
-310,7
+317,7
@@
run_compilebench() {
# t-f _base needs to be modifyed to set properly tdir
# for new "test_foo" functions names
# local testdir=$DIR/$tdir
# t-f _base needs to be modifyed to set properly tdir
# for new "test_foo" functions names
# local testdir=$DIR/$tdir
- local testdir=$
DIR
/d0.compilebench
+ local testdir=$
dir
/d0.compilebench
mkdir -p $testdir
local savePWD=$PWD
mkdir -p $testdir
local savePWD=$PWD