[hipl-commit] [trunk] Rev 3804: script actually requires tee append option

  • From: Rene Hummen <rene.hummen@xxxxxxxxxxxxxxxxx>
  • To: hipl-commit@xxxxxxxxxxxxx
  • Date: Thu, 4 Mar 2010 19:31:37 +0200

Committer: Rene Hummen <rene.hummen@xxxxxxxxxxxxxxxxx>
Date: Thu Mar 04 18:30:54 2010 +0100
Revision: 3804
Revision-id: rene.hummen@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Branch nick: trunk

Log:
  script actually requires tee append option
  
  NOTE: long parameters are not supported by busybox tee

Modified:
  M  test/performance/perf_measure.sh

=== modified file 'test/performance/perf_measure.sh'
--- test/performance/perf_measure.sh    2010-03-04 17:20:34 +0000
+++ test/performance/perf_measure.sh    2010-03-04 17:30:54 +0000
@@ -69,7 +69,7 @@
 
 if [ ! $FILE = "" ]
 then
-  OUTPUT="tee $FILE"
+  OUTPUT="tee -a $FILE"
   RTT_POSTFIX="-rtt"
   TCP_POSTFIX="-tcp"
   UDP_POSTFIX="-udp"
@@ -82,6 +82,12 @@
 then
   read -p "Measure RTT: [ENTER]" TMP
 
+  # remove old measurement
+  if [ -e $OUTPUT$RTT_POSTFIX ]
+  then
+    rm $OUTPUT$RTT_POSTFIX
+  fi
+
   if [ ! $REMOTE_ADDRESS = "0" ]
   then
     if [ $ADDR_FAMILY -eq "4" ]
@@ -110,6 +116,12 @@
   if [ $RUN_MODE -eq "1" -a ! $REMOTE_ADDRESS = "0" ]
   then
 
+    # remove old measurement
+    if [ -e $OUTPUT$TCP_POSTFIX ]
+    then
+      rm $OUTPUT$TCP_POSTFIX
+    fi
+
     i=0
 
     if [ $ADDR_FAMILY -eq "4" ]
@@ -161,6 +173,12 @@
   if [ $RUN_MODE -eq "1" -a ! $REMOTE_ADDRESS = "0" ]
   then
 
+    # remove old measurement
+    if [ -e $OUTPUT$UDP_POSTFIX ]
+    then
+      rm $OUTPUT$UDP_POSTFIX
+    fi
+
     i=0
 
     if [ $ADDR_FAMILY -eq "4" ]

Other related posts:

  • » [hipl-commit] [trunk] Rev 3804: script actually requires tee append option - Rene Hummen