* [PATCH 1/2] queuelat: Assume queuelat and queuelat scripts are in the path
@ 2019-05-07 15:35 John Kacur
2019-05-07 15:35 ` [PATCH 2/2] queuelat: Install queuelat helper scripts from the rt-tests Makefile John Kacur
0 siblings, 1 reply; 2+ messages in thread
From: John Kacur @ 2019-05-07 15:35 UTC (permalink / raw)
To: rt-users; +Cc: Clark Williams, John Kacur
Assume queuelat and queuelat scripts are in the path. Don't hardcode
their location.
Write the temporary data to /usr/tmp/outfile
Signed-off-by: John Kacur <jkacur@redhat.com>
---
src/queuelat/determine_maximum_mpps.sh | 35 +++++++++++++-------------
1 file changed, 17 insertions(+), 18 deletions(-)
diff --git a/src/queuelat/determine_maximum_mpps.sh b/src/queuelat/determine_maximum_mpps.sh
index cf7a8cab9cc4..cd45454720f7 100755
--- a/src/queuelat/determine_maximum_mpps.sh
+++ b/src/queuelat/determine_maximum_mpps.sh
@@ -8,6 +8,7 @@
PREAMBLE="taskset -c 2 chrt -f 1"
MAXLAT="20000"
CYCLES_PER_PACKET="300"
+OUTFILE=/usr/tmp/outfile
echo "Determining maximum mpps the machine can handle"
echo "Will take a few minutes to determine mpps value"
@@ -16,10 +17,10 @@ echo "And 10 minutes run to confirm the final mpps value is stable"
for mpps in `seq 3 3 50`; do
echo testing $mpps Mpps
- outfile=`mktemp`
- $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh ./get_cpuinfo_mhz.sh` -p $mpps -t 30 > $outfile
+ OUTFILE=`mktemp`
+ $PREAMBLE queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh get_cpuinfo_mhz.sh` -p $mpps -t 30 > $OUTFILE
- exceeded=`grep exceeded $outfile`
+ exceeded=`grep exceeded $OUTFILE`
if [ ! -z "$exceeded" ]; then
echo mpps failed: $mpps
break;
@@ -32,10 +33,10 @@ first_mpps=$(($mpps - 1))
for mpps in `seq $first_mpps -1 3`; do
echo testing $mpps Mpps
- outfile=`mktemp`
- $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh ./get_cpuinfo_mhz.sh` -p $mpps -t 30 > $outfile
+ OUTFILE=`mktemp`
+ $PREAMBLE queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh get_cpuinfo_mhz.sh` -p $mpps -t 30 > $OUTFILE
- exceeded=`grep exceeded $outfile`
+ exceeded=`grep exceeded $OUTFILE`
if [ -z "$exceeded" ]; then
echo mpps success $mpps
break;
@@ -49,10 +50,10 @@ echo second loop mpps: $mpps
for mpps in `seq $second_mpps 0.3 $first_mpps`; do
echo testing $mpps Mpps
- outfile=`mktemp`
- $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh ./get_cpuinfo_mhz.sh` -p $mpps -t 30 > $outfile
+ OUTFILE=`mktemp`
+ $PREAMBLE queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh get_cpuinfo_mhz.sh` -p $mpps -t 30 > $OUTFILE
- exceeded=`grep exceeded $outfile`
+ exceeded=`grep exceeded $OUTFILE`
if [ ! -z "$exceeded" ]; then
echo mpps failure $mpps
break;
@@ -66,10 +67,10 @@ third_mpps=`echo "$mpps -0.1" | bc`
for mpps in `seq $third_mpps -0.1 3`; do
echo testing $mpps Mpps
- outfile=`mktemp`
- $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh ./get_cpuinfo_mhz.sh` -p $mpps -t 30 > $outfile
+ OUTFILE=`mktemp`
+ $PREAMBLE queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `sh get_cpuinfo_mhz.sh` -p $mpps -t 30 > $OUTFILE
- exceeded=`grep exceeded $outfile`
+ exceeded=`grep exceeded $OUTFILE`
if [ -z "$exceeded" ]; then
echo mpps success $mpps
break;
@@ -86,8 +87,8 @@ while [ $queuelat_failure == 1 ]; do
echo "$mpps Mpps"
for i in `seq 1 10`; do
- $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `./get_cpuinfo_mhz.sh` -p $mpps -t 30 > $outfile
- exceeded=`grep exceeded $outfile`
+ $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `get_cpuinfo_mhz.sh` -p $mpps -t 30 > $OUTFILE
+ exceeded=`grep exceeded $OUTFILE`
if [ ! -z "$exceeded" ]; then
echo "mpps failure (run $i) $mpps"
@@ -108,8 +109,8 @@ while [ $queuelat_failure == 1 ]; do
echo -n "Starting 10 minutes run with "
echo "$mpps Mpps"
- $PREAMBLE ./queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `./get_cpuinfo_mhz.sh` -p $mpps -t 600 > $outfile
- exceeded=`grep exceeded $outfile`
+ $PREAMBLE queuelat -m $MAXLAT -c $CYCLES_PER_PACKET -f `get_cpuinfo_mhz.sh` -p $mpps -t 600 > $OUTFILE
+ exceeded=`grep exceeded $OUTFILE`
if [ ! -z "$exceeded" ]; then
echo "mpps failure (run $i) $mpps"
@@ -124,5 +125,3 @@ echo Final mpps is: $mpps
unset queuelat_failure
unset mpps
-
-
--
2.20.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH 2/2] queuelat: Install queuelat helper scripts from the rt-tests Makefile
2019-05-07 15:35 [PATCH 1/2] queuelat: Assume queuelat and queuelat scripts are in the path John Kacur
@ 2019-05-07 15:35 ` John Kacur
0 siblings, 0 replies; 2+ messages in thread
From: John Kacur @ 2019-05-07 15:35 UTC (permalink / raw)
To: rt-users; +Cc: Clark Williams, John Kacur
Install queuelat helper scripts from the rt-tests Makefile
Signed-off-by: John Kacur <jkacur@redhat.com>
---
Makefile | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Makefile b/Makefile
index 16cd2f9bdd03..ea80923918f7 100644
--- a/Makefile
+++ b/Makefile
@@ -180,6 +180,8 @@ install: all install_hwlatdetect
mkdir -p "$(DESTDIR)$(bindir)" "$(DESTDIR)$(mandir)/man4"
mkdir -p "$(DESTDIR)$(srcdir)" "$(DESTDIR)$(mandir)/man8"
cp $(TARGETS) "$(DESTDIR)$(bindir)"
+ install src/queuelat/get_cpuinfo_mhz.sh "$(DESTDIR)$(bindir)"
+ install src/queuelat/determine_maximum_mpps.sh "${DESTDIR}${bindir}"
gzip -c src/cyclictest/cyclictest.8 >"$(DESTDIR)$(mandir)/man8/cyclictest.8.gz"
gzip -c src/pi_tests/pi_stress.8 >"$(DESTDIR)$(mandir)/man8/pi_stress.8.gz"
gzip -c src/ptsematest/ptsematest.8 >"$(DESTDIR)$(mandir)/man8/ptsematest.8.gz"
--
2.20.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-05-07 15:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-07 15:35 [PATCH 1/2] queuelat: Assume queuelat and queuelat scripts are in the path John Kacur
2019-05-07 15:35 ` [PATCH 2/2] queuelat: Install queuelat helper scripts from the rt-tests Makefile John Kacur
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).