Commit 0d6fabb9 authored by Raphael Defosseux's avatar Raphael Defosseux

CI: fixed the iperf analysis in 5G-RF-SIM now that we have UL

    also added the UL test for 5G-RF-SIM
Signed-off-by: default avatarRaphael Defosseux <raphael.defosseux@eurecom.fr>
parent 9f135080
...@@ -730,8 +730,8 @@ function report_test { ...@@ -730,8 +730,8 @@ function report_test {
IPERF_TESTS=`ls $ARCHIVES_LOC/${TMODE}_${BW}prb_${CN_CONFIG}_iperf_dl*client*txt 2> /dev/null` IPERF_TESTS=`ls $ARCHIVES_LOC/${TMODE}_${BW}prb_${CN_CONFIG}_iperf_dl*client*txt 2> /dev/null`
analyzeIperfFiles analyzeIperfFiles
#IPERF_TESTS=`ls $ARCHIVES_LOC/${TMODE}_${BW}MHz_${UES}users_${CN_CONFIG}_iperf_ul*client*txt 2> /dev/null` IPERF_TESTS=`ls $ARCHIVES_LOC/${TMODE}_${BW}prb_${CN_CONFIG}_iperf_ul*client*txt 2> /dev/null`
#analyzeIperfFiles analyzeIperfFiles
done done
done done
done done
......
...@@ -342,6 +342,7 @@ function check_iperf { ...@@ -342,6 +342,7 @@ function check_iperf {
local FILE_COMPLETE=`egrep -c "Server Report" ${LOC_BASE_LOG}_client.txt` local FILE_COMPLETE=`egrep -c "Server Report" ${LOC_BASE_LOG}_client.txt`
if [ $FILE_COMPLETE -eq 0 ] if [ $FILE_COMPLETE -eq 0 ]
then then
# This part will become obsolete once we have UL
if [[ $LOC_IS_RF_SIM -eq 1 ]] && [[ $LOC_IS_NR -eq 1 ]] if [[ $LOC_IS_RF_SIM -eq 1 ]] && [[ $LOC_IS_NR -eq 1 ]]
then then
echo "no UL integration right now --> normal to have no server report" echo "no UL integration right now --> normal to have no server report"
...@@ -350,11 +351,11 @@ function check_iperf { ...@@ -350,11 +351,11 @@ function check_iperf {
local EFFECTIVE_BANDWIDTH=`tail -n1 ${LOC_BASE_LOG}_server.txt | sed -e "s#^.*MBytes *##" -e "s#^.*KBytes *##" -e "s#sec.*#sec#"` local EFFECTIVE_BANDWIDTH=`tail -n1 ${LOC_BASE_LOG}_server.txt | sed -e "s#^.*MBytes *##" -e "s#^.*KBytes *##" -e "s#sec.*#sec#"`
if [[ $2 =~ .*K.* ]] if [[ $2 =~ .*K.* ]]
then then
local BW_SUFFIX="K" local BW_PREFIX="K"
else else
local BW_SUFFIX="M" local BW_PREFIX="M"
fi fi
if [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW}.*${BW_SUFFIX}bits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_ONE}.*${BW_SUFFIX}bits.* ]] if [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW}.*${BW_PREFIX}bits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_ONE}.*${BW_PREFIX}bits.* ]]
then then
echo "got requested DL bandwidth: $EFFECTIVE_BANDWIDTH" echo "got requested DL bandwidth: $EFFECTIVE_BANDWIDTH"
else else
...@@ -370,10 +371,19 @@ function check_iperf { ...@@ -370,10 +371,19 @@ function check_iperf {
echo "File Report not found" echo "File Report not found"
fi fi
else else
if [ `egrep -c "Mbits/sec" ${LOC_BASE_LOG}_client.txt` -ne 0 ]
then
local EFFECTIVE_BANDWIDTH=`tail -n3 ${LOC_BASE_LOG}_client.txt | egrep "Mbits/sec" | sed -e "s#^.*MBytes *##" -e "s#sec.*#sec#"` local EFFECTIVE_BANDWIDTH=`tail -n3 ${LOC_BASE_LOG}_client.txt | egrep "Mbits/sec" | sed -e "s#^.*MBytes *##" -e "s#sec.*#sec#"`
local BW_PREFIX="M"
fi
if [ `egrep -c "Kbits/sec" ${LOC_BASE_LOG}_client.txt` -ne 0 ]
then
local EFFECTIVE_BANDWIDTH=`tail -n3 ${LOC_BASE_LOG}_client.txt | egrep "Kbits/sec" | sed -e "s#^.*KBytes *##" -e "s#sec.*#sec#"`
local BW_PREFIX="K"
fi
if [ $LOC_IS_DL -eq 1 ] && [ $LOC_IS_BASIC_SIM -eq 1 ] if [ $LOC_IS_DL -eq 1 ] && [ $LOC_IS_BASIC_SIM -eq 1 ]
then then
if [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW}.*Mbits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_ONE}.*Mbits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_TWO}.*Mbits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_THREE}.*Mbits.* ]] if [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW}.*${BW_PREFIX}bits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_ONE}.*${BW_PREFIX}bits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_TWO}.*${BW_PREFIX}bits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_THREE}.*${BW_PREFIX}bits.* ]]
then then
echo "got requested DL bandwidth: $EFFECTIVE_BANDWIDTH" echo "got requested DL bandwidth: $EFFECTIVE_BANDWIDTH"
else else
...@@ -381,7 +391,7 @@ function check_iperf { ...@@ -381,7 +391,7 @@ function check_iperf {
IPERF_STATUS=-1 IPERF_STATUS=-1
fi fi
else else
if [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW}.*Mbits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_ONE}.*Mbits.* ]] if [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW}.*${BW_PREFIX}bits.* ]] || [[ $EFFECTIVE_BANDWIDTH =~ .*${LOC_REQ_BW_MINUS_ONE}.*${BW_PREFIX}bits.* ]]
then then
if [ $LOC_IS_DL -eq 1 ] if [ $LOC_IS_DL -eq 1 ]
then then
...@@ -390,7 +400,7 @@ function check_iperf { ...@@ -390,7 +400,7 @@ function check_iperf {
echo "got requested UL bandwidth: $EFFECTIVE_BANDWIDTH" echo "got requested UL bandwidth: $EFFECTIVE_BANDWIDTH"
fi fi
else else
echo "not basic-sim got LESS than requested DL bandwidth: $EFFECTIVE_BANDWIDTH" echo "got LESS than requested DL bandwidth: $EFFECTIVE_BANDWIDTH"
IPERF_STATUS=-1 IPERF_STATUS=-1
fi fi
fi fi
...@@ -2067,7 +2077,7 @@ function run_test_on_vm { ...@@ -2067,7 +2077,7 @@ function run_test_on_vm {
fi fi
echo "############################################################" echo "############################################################"
echo "${CN_CONFIG} : iperf DL -- UE is server and eNB is client" echo "${CN_CONFIG} : iperf DL -- NR-UE is server and gNB is client"
echo "############################################################" echo "############################################################"
THROUGHPUT="30K" THROUGHPUT="30K"
CURR_IPERF_LOG_BASE=tdd_${PRB}prb_${CN_CONFIG}_iperf_dl CURR_IPERF_LOG_BASE=tdd_${PRB}prb_${CN_CONFIG}_iperf_dl
...@@ -2078,6 +2088,18 @@ function run_test_on_vm { ...@@ -2078,6 +2088,18 @@ function run_test_on_vm {
scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/${CURR_IPERF_LOG_BASE}_server.txt $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/${CURR_IPERF_LOG_BASE}_server.txt $ARCHIVES_LOC
check_iperf $ARCHIVES_LOC/$CURR_IPERF_LOG_BASE $THROUGHPUT check_iperf $ARCHIVES_LOC/$CURR_IPERF_LOG_BASE $THROUGHPUT
echo "############################################################"
echo "${CN_CONFIG} : iperf UL -- gNB is server and NR-UE is client"
echo "############################################################"
THROUGHPUT="30K"
CURR_IPERF_LOG_BASE=tdd_${PRB}prb_${CN_CONFIG}_iperf_ul
get_enb_noS1_ip_addr $GNB_VM_CMDS $GNB_VM_IP_ADDR
get_ue_ip_addr $NR_UE_VM_CMDS $NR_UE_VM_IP_ADDR 1
generic_iperf $GNB_VM_CMDS $GNB_VM_IP_ADDR $ENB_IP_ADDR $NR_UE_VM_CMDS $NR_UE_VM_IP_ADDR $UE_IP_ADDR $THROUGHPUT $CURR_IPERF_LOG_BASE 1 0
scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/${CURR_IPERF_LOG_BASE}_server.txt $ARCHIVES_LOC
scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/${CURR_IPERF_LOG_BASE}_client.txt $ARCHIVES_LOC
check_iperf $ARCHIVES_LOC/$CURR_IPERF_LOG_BASE $THROUGHPUT
echo "############################################################" echo "############################################################"
echo "${CN_CONFIG} : Terminate gNB/NR-UE simulators" echo "${CN_CONFIG} : Terminate gNB/NR-UE simulators"
echo "############################################################" echo "############################################################"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment