projects
/
anna.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
ab588df
)
improvs.
author
Eduardo Ramos Testillano
<eduardo.ramos.testillano@ericsson.com>
Sat, 29 Oct 2016 14:22:50 +0000
(16:22 +0200)
committer
Eduardo Ramos Testillano
<eduardo.ramos.testillano@ericsson.com>
Sat, 29 Oct 2016 14:22:50 +0000
(16:22 +0200)
example/diameter/launcher/deployments/st-client/checkStatus.sh
patch
|
blob
|
history
example/diameter/launcher/deployments/st-client/configure.sh
patch
|
blob
|
history
example/diameter/launcher/deployments/st-client/launchCPS.sh
patch
|
blob
|
history
example/diameter/launcher/deployments/st-client/program.sh
patch
|
blob
|
history
diff --git
a/example/diameter/launcher/deployments/st-client/checkStatus.sh
b/example/diameter/launcher/deployments/st-client/checkStatus.sh
index
ca132a8
..
fc14686
100755
(executable)
--- a/
example/diameter/launcher/deployments/st-client/checkStatus.sh
+++ b/
example/diameter/launcher/deployments/st-client/checkStatus.sh
@@
-1,4
+1,5
@@
#!/bin/bash
#!/bin/bash
+# Result code: 1 (miss instances (and connections)), 2 (miss connections)
ADML_CONNECTIONS=`cat .st_conf_adml_connections 2>/dev/null`
ADML_INSTANCES=`cat .st_conf_adml_instances 2>/dev/null`
RESULT_CODE=0
ADML_CONNECTIONS=`cat .st_conf_adml_connections 2>/dev/null`
ADML_INSTANCES=`cat .st_conf_adml_instances 2>/dev/null`
RESULT_CODE=0
@@
-16,10
+17,10
@@
fi
ADML_CONNECTIONS_ALIVE=$(netstat -a | grep :diameter | grep ESTABLISHED | wc -l)
ADML_TOTAL_CONNECTIONS=$((ADML_CONNECTIONS*ADML_INSTANCES))
echo -n "$ADML_CONNECTIONS_ALIVE connections established"
ADML_CONNECTIONS_ALIVE=$(netstat -a | grep :diameter | grep ESTABLISHED | wc -l)
ADML_TOTAL_CONNECTIONS=$((ADML_CONNECTIONS*ADML_INSTANCES))
echo -n "$ADML_CONNECTIONS_ALIVE connections established"
-if [ $ADML_CONNECTIONS_ALIVE -ne $ADML_TOTAL_CONNECTIONS ]
&& RESULT_CODE=1
+if [ $ADML_CONNECTIONS_ALIVE -ne $ADML_TOTAL_CONNECTIONS ]
then
echo " ! (expected $ADML_TOTAL_CONNECTIONS configured)"
then
echo " ! (expected $ADML_TOTAL_CONNECTIONS configured)"
- RESULT_CODE=1
+ [ $RESULT_CODE -ne 1 ] && RESULT_CODE=
else
echo
fi
else
echo
fi
diff --git
a/example/diameter/launcher/deployments/st-client/configure.sh
b/example/diameter/launcher/deployments/st-client/configure.sh
index
aac19ab
..
21e3112
100755
(executable)
--- a/
example/diameter/launcher/deployments/st-client/configure.sh
+++ b/
example/diameter/launcher/deployments/st-client/configure.sh
@@
-62,7
+62,7
@@
calculate_deployment_layout() {
do
instances=$(ceil $max_connections $conn)
echo -n -e "\t$instances"
do
instances=$(ceil $max_connections $conn)
echo -n -e "\t$instances"
- [ $conn -eq
2
] && instances__dflt=$instances
+ [ $conn -eq
1
] && instances__dflt=$instances
done
echo
echo -e "Connects per instance:\t10\t9\t8\t7\t6\t5\t4\t3\t2\t1"
done
echo
echo -e "Connects per instance:\t10\t9\t8\t7\t6\t5\t4\t3\t2\t1"
diff --git
a/example/diameter/launcher/deployments/st-client/launchCPS.sh
b/example/diameter/launcher/deployments/st-client/launchCPS.sh
index
08bf495
..
44d993a
100755
(executable)
--- a/
example/diameter/launcher/deployments/st-client/launchCPS.sh
+++ b/
example/diameter/launcher/deployments/st-client/launchCPS.sh
@@
-30,11
+30,13
@@
if [ "$desired_rate" != "" ]
then
rate_per_instance=$((desired_rate/$ADML_INSTANCES))
fi
then
rate_per_instance=$((desired_rate/$ADML_INSTANCES))
fi
-echo "This configures $rate_per_instance test cases per second and instance"
-echo " (there are $ADML_INSTANCES instances available)".
+CMD="./operation.sh \"test|ttps|$rate_per_instance\""
+
+echo
+echo "As we have $ADML_INSTANCES instances available, we shall launch $rate_per_instance test cases"
+echo " per second and instance ($CMD)."
echo
echo "Press ENTER to continue, CTRL-C to abort ..."
read dummy
echo
echo "Press ENTER to continue, CTRL-C to abort ..."
read dummy
-
-./operation.sh "test|ttps|$rate_per_instance"
+$CMD
diff --git
a/example/diameter/launcher/deployments/st-client/program.sh
b/example/diameter/launcher/deployments/st-client/program.sh
index
53090ab
..
31eb97d
100755
(executable)
--- a/
example/diameter/launcher/deployments/st-client/program.sh
+++ b/
example/diameter/launcher/deployments/st-client/program.sh
@@
-8,7
+8,7
@@
RATE_PER_INSTANCE=`cat .st_conf_rate_per_instance 2>/dev/null`
DESIRED_RATE=`cat .st_conf_desired_rate 2>/dev/null`
REPEATS=`cat .st_conf_cycle_repeats 2>/dev/null`
PROGRAM_LAYOUT_FILE=.st_conf_n_testcases_program_layout
DESIRED_RATE=`cat .st_conf_desired_rate 2>/dev/null`
REPEATS=`cat .st_conf_cycle_repeats 2>/dev/null`
PROGRAM_LAYOUT_FILE=.st_conf_n_testcases_program_layout
-[ -z "$ADML_CONCURRENT_PROVISION_JOBS" ] && ADML_CONCURRENT_PROVISION_JOBS=
1
0
+[ -z "$ADML_CONCURRENT_PROVISION_JOBS" ] && ADML_CONCURRENT_PROVISION_JOBS=
2
0
#############
# FUNCTIONS #
#############
# FUNCTIONS #
@@
-89,6
+89,8
@@
advice_to_squeeze_idle_cpu () {
echo "Idle cpu now: $idle. Check the system CPU with top. If is not overcommited, consider"
echo " increase the environment variable 'ADML_CONCURRENT_PROVISION_JOBS' (now $ADML_CONCURRENT_PROVISION_JOBS)."
echo
echo "Idle cpu now: $idle. Check the system CPU with top. If is not overcommited, consider"
echo " increase the environment variable 'ADML_CONCURRENT_PROVISION_JOBS' (now $ADML_CONCURRENT_PROVISION_JOBS)."
echo
+ echo "Press ENTER to continue ..."
+ read dummy
}
#############
}
#############
@@
-108,7
+110,7
@@
echo "Testcases programming ..."
echo
cd `dirname $0`
./checkStatus.sh
echo
cd `dirname $0`
./checkStatus.sh
-[ $? -
ne 0
] && _exit "Fix status to continue ..."
+[ $? -
eq 1
] && _exit "Fix status to continue ..."
# We launch in background !
#./operation.sh --ping >/dev/null
# We launch in background !
#./operation.sh --ping >/dev/null