Whamcloud - gitweb
TT-59 remove . and - from the node name
[fs/lustre-release.git] / lustre / tests / replay-vbr.sh
index 29d47ee..a5a71ec 100644 (file)
@@ -61,17 +61,17 @@ rmultiop_start() {
     local multiop_pid
     multiop_pid=$(do_node $client cat $pid_file)
     [ -n "$multiop_pid" ] || error "$client : Can not get multiop_pid from $pid_file "
-    eval export $(client_var_name $client)_multiop_pid=$multiop_pid
-    eval export $(client_var_name $client)_do_node_pid=$pid
-    local var=$(client_var_name $client)_multiop_pid
+    eval export $(node_var_name $client)_multiop_pid=$multiop_pid
+    eval export $(node_var_name $client)_do_node_pid=$pid
+    local var=$(node_var_name $client)_multiop_pid
     echo client $client multiop_bg started multiop_pid=${!var}
     return $?
 }
 
 rmultiop_stop() {
     local client=$1
-    local multiop_pid=$(client_var_name $client)_multiop_pid
-    local do_node_pid=$(client_var_name $client)_do_node_pid
+    local multiop_pid=$(node_var_name $client)_multiop_pid
+    local do_node_pid=$(node_var_name $client)_do_node_pid
 
     echo "Stopping multiop_pid=${!multiop_pid} (kill ${!multiop_pid} on $client)"
     do_node $client kill -USR1 ${!multiop_pid}
@@ -454,7 +454,7 @@ test_4j() { # former test_0q
 
     do_node $CLIENT1 mcreate $file
     pre=$(get_version $CLIENT1 $file)
-    do_node $CLIENT1 truncate $file 1
+    do_node $CLIENT1 $TRUNCATE $file 1
     post=$(get_version $CLIENT1 $file)
     if (($pre != $post)); then
         error "version changed unexpectedly: pre $pre, post $post"
@@ -478,7 +478,7 @@ test_4k() { # former test_0r
 
     replay_barrier $SINGLEMDS
     do_node $CLIENT2 chmod 666 $MOUNT2/$tfile
-    do_node $CLIENT1 truncate $file 1
+    do_node $CLIENT1 $TRUNCATE $file 1
     sleep 1
     mtime_pre=$(do_node $CLIENT1 stat --format=%Y $file)
     do_node $CLIENT1 touch $file
@@ -1010,7 +1010,7 @@ test_10b() { # former test_2b
     do_node $CLIENT2 chmod 666 $DIR1/$tfile-b           # R
     do_node $CLIENT2 chgrp $RUNAS_GID $DIR2/$tfile-a    # U
     do_node $CLIENT1 chown $RUNAS_ID:$RUNAS_GID $DIR/$tfile-a      # J
-    do_node $CLIENT2 truncate $DIR2/$tfile-b 1          # U
+    do_node $CLIENT2 $TRUNCATE $DIR2/$tfile-b 1          # U
     do_node $CLIENT2 chgrp $RUNAS_GID $DIR1/$tfile-b    # R
     do_node $CLIENT1 chown $RUNAS_ID:$RUNAS_GID $DIR/$tfile-b      # R
     zconf_umount $CLIENT2 $MOUNT2
@@ -1132,6 +1132,6 @@ rm -f $cos_param_file
 
 [ "$CLIENTS" ] && zconf_mount_clients $CLIENTS $DIR
 
-equals_msg `basename $0`: test complete, cleaning up
+complete $(basename $0) $SECONDS
 check_and_cleanup_lustre
-[ -f "$TESTSUITELOG" ] && cat $TESTSUITELOG && grep -q FAIL $TESTSUITELOG && exit 1 || true
+exit_status