diff --git a/ci-scripts/.gitignore b/ci-scripts/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..d77a672c0c57e050ddc87037492ffa5cb474cea7 --- /dev/null +++ b/ci-scripts/.gitignore @@ -0,0 +1,7 @@ +enb_*.log +ue_*.log +ping_*.* +iperf_*.* +phones_list.txt +modules_list.txt +test_results*.html diff --git a/ci-scripts/Jenkinsfile-inria-r2lab b/ci-scripts/Jenkinsfile-inria-r2lab new file mode 100644 index 0000000000000000000000000000000000000000..6fe2e3bb2a6aceaaa671b3ba08a231eeeb4700d5 --- /dev/null +++ b/ci-scripts/Jenkinsfile-inria-r2lab @@ -0,0 +1,408 @@ +#!/bin/groovy +/* + * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The OpenAirInterface Software Alliance licenses this file to You under + * the OAI Public License, Version 1.1 (the "License"); you may not use this file + * except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.openairinterface.org/?page_id=698 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + *------------------------------------------------------------------------------- + * For more information about the OpenAirInterface (OAI) Software Alliance: + * contact@openairinterface.org + */ + +// Abstraction function to send social media messages: +// like on Slack or Mattermost +def sendSocialMediaMessage(pipeChannel, pipeColor, pipeMessage) { + if (params.pipelineUsesSlack != null) { + if (params.pipelineUsesSlack) { + slackSend channel: pipeChannel, color: pipeColor, message: pipeMessage + } + } +} + +// Location of the test XML file to be run +def testXMLFile = params.pythonTestXmlFile +def mainPythonAllXmlFiles = "" +def buildStageStatus = true + +// Name of the test stage +def testStageName = params.pipelineTestStageName + +// Name of the branch to work on +def ranRepoBranch = params.pythonWorkingBranch + +// Lease booking parameters +def r2labStartTime = params.R2LAB_LeaseBookStartTime +def r2labDuration = params.R2LAB_LeaseBookDuration + + +// Fixed deployment +def r2labBaseIpAddr = '192.168.3.' +def r2labPythonExeIdx = '14' +def r2labPythonExe = 'fit' + r2labPythonExeIdx +def r2labENB0Idx = '23' +def r2labENB0 = 'fit' + r2labENB0Idx +def r2labENB0IpAddr = r2labBaseIpAddr + r2labENB0Idx +def r2labEPC0Idx = '17' +def r2labEPC0 = 'fit' + r2labEPC0Idx +def r2labEPC0IpAddr = r2labBaseIpAddr + r2labEPC0Idx +def r2labUE0Idx = '6' +def r2labUE0 = 'fit0' + r2labUE0Idx +def r2labUE0IpAddr = r2labBaseIpAddr + r2labUE0Idx + +pipeline { + agent { + label 'master' + } + + options { + disableConcurrentBuilds() + timestamps() + ansiColor('xterm') + } + + stages { + stage ("Book session") { + steps { + script { + echo '\u2705 \u001B[32mVerify Parameters\u001B[0m' + + def allParametersPresent = true + if (params.R2LAB_Credentials == null) { + allParametersPresent = false + } + if (params.R2LAB_FitNode_Credentials == null) { + allParametersPresent = false + } + if (params.R2LAB_LeaseBookStartTime == null) { + allParametersPresent = false + } + if (params.R2LAB_LeaseBookDuration == null) { + allParametersPresent = false + } + + // If not present picking a default Stage Name + if (params.pipelineTestStageName == null) { + // picking default + testStageName = 'Tests at Inria R2LAB' + } + // If not present picking a default branch name + if (params.pythonWorkingBranch == null) { + ranRepoBranch = 'develop' + } + + if (params.pythonTestXmlFile == null) { + // picking default + testXMLFile = 'xml_files/inria/enb_usrp210_band7_build.xml' + echo "Test XML file(default): ${testXMLFile}" + mainPythonAllXmlFiles += "--XMLTestFile=" + testXMLFile + " " + } else { + String[] myXmlTestSuite = testXMLFile.split("\\r?\\n") + for (xmlFile in myXmlTestSuite) { + mainPythonAllXmlFiles += "--XMLTestFile=" + xmlFile + " " + echo "Test XML file : ${xmlFile}" + } + } + + if (!allParametersPresent) { + currentBuild.result = 'ABORTED' + error('Stopping early because no R2LAB credentials') + } + + JOB_TIMESTAMP = sh returnStdout: true, script: 'date --rfc-3339=seconds | sed -e "s#+00:00##"' + JOB_TIMESTAMP = JOB_TIMESTAMP.trim() + + echo '\u2705 \u001B[32mBook a Session\u001B[0m' + + BOOK_TIMESTAMP = sh returnStdout: true, script: 'date --rfc-3339=date' + BOOK_TIMESTAMP = BOOK_TIMESTAMP.trim() + + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_Credentials}", usernameVariable: 'r2labuser', passwordVariable: 'r2labpassword'] + ]) { + sh "python3 /home/eurecom/inria-scripts/booking-lease.py --book-lease --from ${BOOK_TIMESTAMP}T${r2labStartTime} --duration ${r2labDuration} --slice inria_oaici ${r2labuser} ${r2labpassword}" + sh "python3 /home/eurecom/inria-scripts/booking-lease.py --get-leases ${r2labuser} ${r2labpassword}" + } + } + } + } + stage ("Load Images") { + steps { + script { + echo '\u2705 \u001B[32mLoad Image for Python Executor\u001B[0m' + sh "ssh -t inria_oaici@faraday.inria.fr 'rload -i oai-ci-cd-u18-lowlatency-enb-ue ${r2labPythonExeIdx} > /dev/null 2>&1'" + sh "ssh -t inria_oaici@faraday.inria.fr 'rwait --silent ${r2labPythonExeIdx}'" + + echo '\u2705 \u001B[32mLoad Image for one eNB\u001B[0m' + sh "ssh -t inria_oaici@faraday.inria.fr 'rload -i oai-ci-cd-u18-lowlatency-enb-ue ${r2labENB0Idx} > /dev/null 2>&1'" + sh "ssh -t inria_oaici@faraday.inria.fr 'rwait --silent ${r2labENB0Idx}'" + sh "ssh -t inria_oaici@faraday.inria.fr 'uon ${r2labENB0Idx}'" + + echo '\u2705 \u001B[32mLoad Image for one OAI UE\u001B[0m' + sh "ssh -t inria_oaici@faraday.inria.fr 'rload -i oai-ci-cd-u18-lowlatency-enb-ue ${r2labUE0Idx} > /dev/null 2>&1'" + sh "ssh -t inria_oaici@faraday.inria.fr 'rwait --silent ${r2labUE0Idx}'" + sh "ssh -t inria_oaici@faraday.inria.fr 'uon ${r2labUE0Idx}'" + + echo '\u2705 \u001B[32mLoad Image for one EPC\u001B[0m' + sh "ssh -t inria_oaici@faraday.inria.fr 'rload -i oai-ci-cd-u18-lowlatency-epc ${r2labEPC0Idx} > /dev/null 2>&1'" + sh "ssh -t inria_oaici@faraday.inria.fr 'rwait --silent ${r2labEPC0Idx}'" + + sh "ssh -t inria_oaici@faraday.inria.fr 'nodes ${r2labUE0Idx},${r2labPythonExeIdx},${r2labEPC0Idx},${r2labENB0Idx} && st'" + } + } + } + stage ("Prepare Python Executor") { + steps { + script { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g && git fetch --all --prune --quiet\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g && git checkout --quiet ${ranRepoBranch}\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g && git pull --quiet origin ${ranRepoBranch}\"'" + GIT_COMMIT_TO_RUN = sh returnStdout: true, script: "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g && git log -n1 --pretty=format:%H\"' | grep -v fit" + GIT_COMMIT_TO_RUN = GIT_COMMIT_TO_RUN.trim() + echo "Latest commit to use is ${GIT_COMMIT_TO_RUN}" + + // Putting the adaptation parameters for the OAI UE + sh "ssh -t inria_oaici@faraday.inria.fr 'scp /home/inria_oaici/for-ci/adapt_usim_parameters_${r2labUE0}.sed ${fituser}@${r2labUE0}:/tmp'" + + // Out of rload, the sub-network-interfaces are not up + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:m11 172.16.1.102 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:m10 192.168.10.110 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:sxu 172.55.55.102 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:s1u 192.168.248.159 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:sxc 172.55.55.101 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:s5c 172.58.58.102 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:p5c 172.58.58.101 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"echo ${fitpasswd} | sudo -S ifconfig control:s11 172.16.1.104 up\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'ssh -t -b 192.168.3.100 ${fituser}@${r2labEPC0} \"ifconfig\"'" + } + } + } + } + stage ("Build and Test") { + steps { + script { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=InitiateHtml --ranRepository=https://gitlab.eurecom.fr/oai/openairinterface5g --ranBranch=${ranRepoBranch} --ranCommitID=${GIT_COMMIT_TO_RUN} --ranAllowMerge=false --ADBIPAddress=${r2labEPC0IpAddr} --ADBUserName=${fituser} --ADBPassword=${fitpasswd} --ADBType=distributed ${mainPythonAllXmlFiles}\"'" + String[] myXmlTestSuite = testXMLFile.split("\\r?\\n") + for (xmlFile in myXmlTestSuite) { + try { + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=TesteNB --ranRepository=https://gitlab.eurecom.fr/oai/openairinterface5g --ranBranch=${ranRepoBranch} --ranCommitID=${GIT_COMMIT_TO_RUN} --ranAllowMerge=false --eNBIPAddress=${r2labENB0IpAddr} --eNBUserName=${fituser} --eNBPassword=${fitpasswd} --eNBSourceCodePath=/home/${fituser}/openairinterface5g --UEIPAddress=${r2labUE0IpAddr} --UEUserName=${fituser} --UEPassword=${fitpasswd} --UESourceCodePath=/home/${fituser}/openairinterface5g --EPCIPAddress=${r2labEPC0IpAddr} --EPCType=OAI-Rel14-CUPS --EPCUserName=${fituser} --EPCPassword=${fitpasswd} --EPCSourceCodePath=/home/${fituser}/openair-cn --ADBIPAddress=${r2labEPC0IpAddr} --ADBUserName=${fituser} --ADBPassword=${fitpasswd} --ADBType=distributed --XMLTestFile=${xmlFile}\"'" + } catch (Exception e) { + currentBuild.result = 'FAILURE' + buildStageStatus = false + } + } + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=FinalizeHtml --finalStatus=${buildStageStatus} --eNBIPAddress=${r2labENB0IpAddr} --eNBUserName=${fituser} --eNBPassword=${fitpasswd}\"'" + } + } + } + } + stage ("Prepare Log Collection") { + steps { + sh "ssh -t inria_oaici@faraday.inria.fr 'mkdir -p /home/inria_oaici/archives'" + sh "ssh -t inria_oaici@faraday.inria.fr 'touch /home/inria_oaici/archives/no_error.txt'" + sh "ssh -t inria_oaici@faraday.inria.fr 'rm -f /home/inria_oaici/archives/*.*'" + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labPythonExe}:/home/${fituser}/openairinterface5g/ci-scripts/test_results.html /home/inria_oaici/archives'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/test_results.html ." + script { + if(fileExists("./test_results.html")) { + sh "mv ./test_results.html test_results-${JOB_NAME}.html" + sh "sed -i -e 's#TEMPLATE_JOB_NAME#${JOB_NAME}#' -e 's@build #TEMPLATE_BUILD_ID@build #${BUILD_ID}@' -e 's#Build-ID: TEMPLATE_BUILD_ID#Build-ID: <a href=\"${BUILD_URL}\">${BUILD_ID}</a>#' -e 's#TEMPLATE_STAGE_NAME#${testStageName}#' -e 's#TEMPLATE_BUILD_TIME#${JOB_TIMESTAMP}#' test_results-${JOB_NAME}.html" + archiveArtifacts "test_results-${JOB_NAME}.html" + } + } + } + } + stage ("Log Collection") { + parallel { + stage('Log Collection (OAI eNB - Build)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (OAI eNB - Build)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectBuild --eNBIPAddress=${r2labENB0IpAddr} --eNBUserName=${fituser} --eNBPassword=${fitpasswd} --eNBSourceCodePath=/home/${fituser}/openairinterface5g\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labENB0}:/home/${fituser}/openairinterface5g/cmake_targets/build.log.zip /home/inria_oaici/archives/enb.build.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/enb.build.log.zip enb.build.log.${env.BUILD_ID}.zip" + script { + if(fileExists("enb.build.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "enb.build.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (OAI UE - Build)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (OAI UE - Build)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectBuild --UEIPAddress=${r2labUE0IpAddr} --UEUserName=${fituser} --UEPassword=${fitpasswd} --UESourceCodePath=/home/${fituser}/openairinterface5g\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labUE0}:/home/${fituser}/openairinterface5g/cmake_targets/build.log.zip /home/inria_oaici/archives/ue.build.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/ue.build.log.zip ue.build.log.${env.BUILD_ID}.zip" + script { + if(fileExists("ue.build.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "ue.build.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (OAI eNB - Runs)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (OAI eNB - Runs)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollecteNB --eNBIPAddress=${r2labENB0IpAddr} --eNBUserName=${fituser} --eNBPassword=${fitpasswd} --eNBSourceCodePath=/home/${fituser}/openairinterface5g\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labENB0}:/home/${fituser}/openairinterface5g/cmake_targets/enb.log.zip /home/inria_oaici/archives/enb.run.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/enb.run.log.zip enb.run.log.${env.BUILD_ID}.zip" + script { + if(fileExists("enb.run.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "enb.run.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (OAI UE - Runs)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (OAI UE - Runs)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectOAIUE --UEIPAddress=${r2labUE0IpAddr} --UEUserName=${fituser} --UEPassword=${fitpasswd} --UESourceCodePath=/home/${fituser}/openairinterface5g\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labUE0}:/home/${fituser}/openairinterface5g/cmake_targets/ue.log.zip /home/inria_oaici/archives/ue.run.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/ue.run.log.zip ue.run.log.${env.BUILD_ID}.zip" + script { + if(fileExists("ue.run.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "ue.run.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (MME)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (MME)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectMME --EPCIPAddress=${r2labEPC0IpAddr} --EPCUserName=${fituser} --EPCPassword=${fitpasswd} --EPCSourceCodePath=/home/${fituser}/openair-cn --EPCType=OAI-Rel14-CUPS\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labEPC0}:/home/${fituser}/openair-cn/scripts/mme.log.zip /home/inria_oaici/archives/mme.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/mme.log.zip mme.log.${env.BUILD_ID}.zip" + script { + if(fileExists("mme.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "mme.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (HSS)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (HSS)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectHSS --EPCIPAddress=${r2labEPC0IpAddr} --EPCUserName=${fituser} --EPCPassword=${fitpasswd} --EPCSourceCodePath=/home/${fituser}/openair-cn --EPCType=OAI-Rel14-CUPS\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labEPC0}:/home/${fituser}/openair-cn/scripts/hss.log.zip /home/inria_oaici/archives/hss.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/hss.log.zip hss.log.${env.BUILD_ID}.zip" + script { + if(fileExists("hss.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "hss.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (SPGW)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (SPGW)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectSPGW --EPCIPAddress=${r2labEPC0IpAddr} --EPCUserName=${fituser} --EPCPassword=${fitpasswd} --EPCSourceCodePath=/home/${fituser}/openair-cn --EPCType=OAI-Rel14-CUPS\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labEPC0}:/home/${fituser}/openair-cn/scripts/spgw.log.zip /home/inria_oaici/archives/spgw.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/spgw.log.zip spgw.log.${env.BUILD_ID}.zip" + script { + if(fileExists("spgw.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "spgw.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (Ping)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (Ping)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectPing --EPCIPAddress=${r2labEPC0IpAddr} --EPCUserName=${fituser} --EPCPassword=${fitpasswd} --EPCSourceCodePath=/home/${fituser}/openair-cn --EPCType=OAI-Rel14-CUPS\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labEPC0}:/home/${fituser}/openair-cn/scripts/ping.log.zip /home/inria_oaici/archives/ping.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/ping.log.zip ping.log.${env.BUILD_ID}.zip" + script { + if(fileExists("ping.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "ping.log.${env.BUILD_ID}.zip" + } + } + } + } + stage('Log Collection (Iperf)') { + steps { + withCredentials([ + [$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.R2LAB_FitNode_Credentials}", usernameVariable: 'fituser', passwordVariable: 'fitpasswd'] + ]) { + echo '\u2705 \u001B[32mLog Collection (Iperf)\u001B[0m' + sh "ssh -t -t inria_oaici@faraday.inria.fr 'ssh -t -t -b 192.168.3.100 ${fituser}@${r2labPythonExe} \"cd openairinterface5g/ci-scripts && python3 main.py --mode=LogCollectIperf --EPCIPAddress=${r2labEPC0IpAddr} --EPCUserName=${fituser} --EPCPassword=${fitpasswd} --EPCSourceCodePath=/home/${fituser}/openair-cn --EPCType=OAI-Rel14-CUPS\"'" + sh "ssh -t inria_oaici@faraday.inria.fr 'scp ${fituser}@${r2labEPC0}:/home/${fituser}/openair-cn/scripts/iperf.log.zip /home/inria_oaici/archives/iperf.log.zip'" + } + sh "scp inria_oaici@faraday.inria.fr:/home/inria_oaici/archives/iperf.log.zip iperf.log.${env.BUILD_ID}.zip" + script { + if(fileExists("iperf.log.${env.BUILD_ID}.zip")) { + archiveArtifacts "iperf.log.${env.BUILD_ID}.zip" + } + } + } + } + } + } + stage ("Clean-up Log Collection") { + steps { + sh "ssh -t inria_oaici@faraday.inria.fr 'rm -Rf /home/inria_oaici/archives'" + } + } + } + + post { + always { + script { + echo '\u2705 \u001B[32mShutdown every node\u001B[0m' + sh 'ssh -t inria_oaici@faraday.inria.fr "all-off"' + sh 'ssh -t inria_oaici@faraday.inria.fr "all-off"' + } + } + } +} diff --git a/ci-scripts/main.py b/ci-scripts/main.py index 3c79e6387a2e49bcd006b80947e36c04361c4d1b..34628fc4f90f123f7c0e15468ec2703309df806a 100644 --- a/ci-scripts/main.py +++ b/ci-scripts/main.py @@ -120,6 +120,7 @@ class SSHConnection(): self.ADBIPAddress = '' self.ADBUserName = '' self.ADBPassword = '' + self.ADBCentralized = True self.testCase_id = '' self.testXMLfiles = [] self.nbTestXMLfiles = 0 @@ -140,6 +141,10 @@ class SSHConnection(): self.nbMaxUEtoAttach = -1 self.UEDevices = [] self.UEDevicesStatus = [] + self.UEDevicesRemoteServer = [] + self.UEDevicesRemoteUser = [] + self.UEDevicesOffCmd = [] + self.UEDevicesOnCmd = [] self.CatMDevices = [] self.UEIPAddresses = [] self.htmlFile = '' @@ -204,7 +209,7 @@ class SSHConnection(): logging.debug('self.sshresponse = ' + str(self.sshresponse)) elif self.sshresponse == 2: # Checking if we are really on the remote client defined by its IP address - self.command('stdbuf -o0 ifconfig | egrep --color=never "inet addr:"', '\$', 5) + self.command('stdbuf -o0 ifconfig | egrep --color=never "inet addr:|inet "', '\$', 5) result = re.search(str(ipaddress), str(self.ssh.before)) if result is None: self.close() @@ -604,19 +609,29 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + logging.debug('Using the OAI EPC Release 14 Cassandra-based HSS') + self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) + self.command('echo ' + self.EPCPassword + ' | sudo -S mkdir -p logs', '\$', 5) + self.command('echo ' + self.EPCPassword + ' | sudo -S rm -f hss.log logs/hss*.*', '\$', 5) + self.command('echo "oai_hss -j /usr/local/etc/oai/hss_rel14.json" > ./my-hss.sh', '\$', 5) + self.command('chmod 755 ./my-hss.sh', '\$', 5) + self.command('sudo daemon --unsafe --name=hss_daemon --chdir=' + self.EPCSourceCodePath + '/scripts -o ' + self.EPCSourceCodePath + '/scripts/hss.log ./my-hss.sh', '\$', 5) + elif re.match('OAI', self.EPCType, re.IGNORECASE): logging.debug('Using the OAI EPC HSS') self.command('cd ' + self.EPCSourceCodePath, '\$', 5) self.command('source oaienv', '\$', 5) self.command('cd scripts', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S ./run_hss 2>&1 | stdbuf -o0 awk \'{ print strftime("[%Y/%m/%d %H:%M:%S] ",systime()) $0 }\' | stdbuf -o0 tee -a hss_' + self.testCase_id + '.log &', 'Core state: 2 -> 3', 35) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): logging.debug('Using the ltebox simulated HSS') self.command('if [ -d ' + self.EPCSourceCodePath + '/scripts ]; then echo ' + self.eNBPassword + ' | sudo -S rm -Rf ' + self.EPCSourceCodePath + '/scripts ; fi', '\$', 5) self.command('mkdir -p ' + self.EPCSourceCodePath + '/scripts', '\$', 5) self.command('cd /opt/hss_sim0609', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S rm -f hss.log daemon.log', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S echo "Starting sudo session" && sudo daemon --unsafe --name=simulated_hss --chdir=/opt/hss_sim0609 ./starthss_real ', '\$', 5) + else: + logging.error('This option should not occur!') self.close() self.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK) @@ -625,7 +640,14 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + logging.debug('Using the OAI EPC Release 14 MME') + self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) + self.command('echo ' + self.EPCPassword + ' | sudo -S rm -f mme.log', '\$', 5) + self.command('echo "./run_mme --config-file /usr/local/etc/oai/mme.conf --set-virt-if" > ./my-mme.sh', '\$', 5) + self.command('chmod 755 ./my-mme.sh', '\$', 5) + self.command('sudo daemon --unsafe --name=mme_daemon --chdir=' + self.EPCSourceCodePath + '/scripts -o ' + self.EPCSourceCodePath + '/scripts/mme.log ./my-mme.sh', '\$', 5) + elif re.match('OAI', self.EPCType, re.IGNORECASE): self.command('cd ' + self.EPCSourceCodePath, '\$', 5) self.command('source oaienv', '\$', 5) self.command('cd scripts', '\$', 5) @@ -636,9 +658,11 @@ class SSHConnection(): sys.exit(1) host_name = result.group('host_name') self.command('echo ' + self.EPCPassword + ' | sudo -S ./run_mme 2>&1 | stdbuf -o0 tee -a mme_' + self.testCase_id + '.log &', 'MME app initialization complete', 100) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cd /opt/ltebox/tools', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S ./start_mme', '\$', 5) + else: + logging.error('This option should not occur!') self.close() self.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK) @@ -647,14 +671,27 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + logging.debug('Using the OAI EPC Release 14 SPGW-CUPS') + self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) + self.command('echo ' + self.EPCPassword + ' | sudo -S rm -f spgwc.log spgwu.log', '\$', 5) + self.command('echo "spgwc -c /usr/local/etc/oai/spgw_c.conf" > ./my-spgwc.sh', '\$', 5) + self.command('chmod 755 ./my-spgwc.sh', '\$', 5) + self.command('sudo daemon --unsafe --name=spgwc_daemon --chdir=' + self.EPCSourceCodePath + '/scripts -o ' + self.EPCSourceCodePath + '/scripts/spgwc.log ./my-spgwc.sh', '\$', 5) + time.sleep(5) + self.command('echo "spgwu -c /usr/local/etc/oai/spgw_u.conf" > ./my-spgwu.sh', '\$', 5) + self.command('chmod 755 ./my-spgwu.sh', '\$', 5) + self.command('sudo daemon --unsafe --name=spgwu_daemon --chdir=' + self.EPCSourceCodePath + '/scripts -o ' + self.EPCSourceCodePath + '/scripts/spgwu.log ./my-spgwu.sh', '\$', 5) + elif re.match('OAI', self.EPCType, re.IGNORECASE): self.command('cd ' + self.EPCSourceCodePath, '\$', 5) self.command('source oaienv', '\$', 5) self.command('cd scripts', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S ./run_spgw 2>&1 | stdbuf -o0 tee -a spgw_' + self.testCase_id + '.log &', 'Initializing SPGW-APP task interface: DONE', 30) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cd /opt/ltebox/tools', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S ./start_xGw', '\$', 5) + else: + logging.error('This option should not occur!') self.close() self.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK) @@ -831,12 +868,18 @@ class SSHConnection(): self.close() - def InitializeUE_common(self, device_id): - logging.debug('send adb commands') + def InitializeUE_common(self, device_id, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) + if not self.ADBCentralized: + # enable data service + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "svc data enable"\'', '\$', 60) + # airplane mode on // radio off + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' ' + self.UEDevicesOffCmd[idx], '\$', 60) + self.close() + return # enable data service - self.command('stdbuf -o0 adb -s ' + device_id + ' shell svc data enable', '\$', 60) + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "svc data enable"', '\$', 60) # The following commands are deprecated since we no longer work on Android 7+ # self.command('stdbuf -o0 adb -s ' + device_id + ' shell settings put global airplane_mode_on 1', '\$', 10) @@ -858,11 +901,13 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') multi_jobs = [] + i = 0 for device_id in self.UEDevices: - p = Process(target = self.InitializeUE_common, args = (device_id,)) + p = Process(target = self.InitializeUE_common, args = (device_id,i,)) p.daemon = True p.start() multi_jobs.append(p) + i += 1 for job in multi_jobs: job.join() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) @@ -897,7 +942,12 @@ class SSHConnection(): result = re.search('--no-L2-connect', str(self.Initialize_OAI_UE_args)) # We may have to regenerate the .u* files if result is None: - self.command('sed -e "s#93#92#" -e "s#8baf473f2f8fd09487cccbd7097c6862#fec86ba6eb707ed08905757b1bb44b8f#" -e "s#e734f8734007d6c5ce7a0508809e7e9c#C42449363BBAD02B66D16BC975D77CC1#" ../../../openair3/NAS/TOOLS/ue_eurecom_test_sfr.conf > ../../../openair3/NAS/TOOLS/ci-ue_eurecom_test_sfr.conf', '\$', 5) + self.command('ls /tmp/*.sed', '\$', 5) + result = re.search('adapt_usim_parameters', str(self.ssh.before)) + if result is not None: + self.command('sed -f /tmp/adapt_usim_parameters.sed ../../../openair3/NAS/TOOLS/ue_eurecom_test_sfr.conf > ../../../openair3/NAS/TOOLS/ci-ue_eurecom_test_sfr.conf', '\$', 5) + else: + self.command('sed -e "s#93#92#" -e "s#8baf473f2f8fd09487cccbd7097c6862#fec86ba6eb707ed08905757b1bb44b8f#" -e "s#e734f8734007d6c5ce7a0508809e7e9c#C42449363BBAD02B66D16BC975D77CC1#" ../../../openair3/NAS/TOOLS/ue_eurecom_test_sfr.conf > ../../../openair3/NAS/TOOLS/ci-ue_eurecom_test_sfr.conf', '\$', 5) self.command('echo ' + self.UEPassword + ' | sudo -S rm -Rf .u*', '\$', 5) self.command('echo ' + self.UEPassword + ' | sudo -S ../../../targets/bin/conf2uedata -c ../../../openair3/NAS/TOOLS/ci-ue_eurecom_test_sfr.conf -o .', '\$', 5) # Launch UE with the modified config file @@ -975,11 +1025,13 @@ class SSHConnection(): result = re.search('--no-L2-connect', str(self.Initialize_OAI_UE_args)) if result is None: self.command('ifconfig oaitun_ue1', '\$', 4) - result = re.search('inet addr', str(self.ssh.before)) + # ifconfig output is different between ubuntu 16 and ubuntu 18 + result = re.search('inet addr 1|inet 1', str(self.ssh.before)) if result is not None: logging.debug('\u001B[1m oaitun_ue1 interface is mounted and configured\u001B[0m') tunnelInterfaceStatus = True else: + logging.debug(str(self.ssh.before)) logging.error('\u001B[1m oaitun_ue1 interface is either NOT mounted or NOT configured\u001B[0m') tunnelInterfaceStatus = False else: @@ -1234,18 +1286,25 @@ class SSHConnection(): except: os.kill(os.getppid(),signal.SIGUSR1) - def AttachUE_common(self, device_id, statusQueue, lock): + def AttachUE_common(self, device_id, statusQueue, lock, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) - if device_id == '84B7N16418004022': - self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/on"', '\$', 60) + if self.ADBCentralized: + if device_id == '84B7N16418004022': + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/on"', '\$', 60) + else: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/on', '\$', 60) else: - self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/on', '\$', 60) + # airplane mode off // radio on + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' ' + self.UEDevicesOnCmd[idx], '\$', 60) time.sleep(2) max_count = 45 count = max_count while count > 0: - self.command('stdbuf -o0 adb -s ' + device_id + ' shell dumpsys telephony.registry | grep mDataConnectionState', '\$', 15) + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "dumpsys telephony.registry" | grep mDataConnectionState', '\$', 15) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "dumpsys telephony.registry"\' | grep mDataConnectionState', '\$', 60) result = re.search('mDataConnectionState.*=(?P<state>[0-9\-]+)', str(self.ssh.before)) if result is None: logging.debug('\u001B[1;37;41m mDataConnectionState Not Found! \u001B[0m') @@ -1267,15 +1326,21 @@ class SSHConnection(): count = count - 1 if count == 15 or count == 30: logging.debug('\u001B[1;30;43m Retry UE (' + device_id + ') Flight Mode Off \u001B[0m') - if device_id == '84B7N16418004022': - self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/off"', '\$', 60) + if self.ADBCentralized: + if device_id == '84B7N16418004022': + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/off"', '\$', 60) + else: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/off', '\$', 60) else: - self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/off', '\$', 60) + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' ' + self.UEDevicesOffCmd[idx], '\$', 60) time.sleep(0.5) - if device_id == '84B7N16418004022': - self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/on"', '\$', 60) + if self.ADBCentralized: + if device_id == '84B7N16418004022': + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/on"', '\$', 60) + else: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/on', '\$', 60) else: - self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/on', '\$', 60) + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' ' + self.UEDevicesOnCmd[idx], '\$', 60) time.sleep(0.5) logging.debug('\u001B[1mWait UE (' + device_id + ') a second until mDataConnectionState=2 (' + str(max_count-count) + ' times)\u001B[0m') time.sleep(1) @@ -1308,7 +1373,7 @@ class SSHConnection(): for device_id in self.UEDevices: if (self.nbMaxUEtoAttach == -1) or (nb_ue_to_connect < self.nbMaxUEtoAttach): self.UEDevicesStatus[nb_ue_to_connect] = UE_STATUS_ATTACHING - p = Process(target = self.AttachUE_common, args = (device_id, status_queue, lock,)) + p = Process(target = self.AttachUE_common, args = (device_id, status_queue, lock,nb_ue_to_connect,)) p.daemon = True p.start() multi_jobs.append(p) @@ -1349,13 +1414,16 @@ class SSHConnection(): self.CreateHtmlTestRowQueue('N/A', 'KO', len(self.UEDevices), html_queue) self.AutoTerminateUEandeNB() - def DetachUE_common(self, device_id): + def DetachUE_common(self, device_id, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) - if device_id == '84B7N16418004022': - self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/off"', '\$', 60) + if self.ADBCentralized: + if device_id == '84B7N16418004022': + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/off"', '\$', 60) + else: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/off', '\$', 60) else: - self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/off', '\$', 60) + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' ' + self.UEDevicesOffCmd[idx], '\$', 60) logging.debug('\u001B[1mUE (' + device_id + ') Detach Completed\u001B[0m') self.close() except: @@ -1376,7 +1444,7 @@ class SSHConnection(): cnt = 0 for device_id in self.UEDevices: self.UEDevicesStatus[cnt] = UE_STATUS_DETACHING - p = Process(target = self.DetachUE_common, args = (device_id,)) + p = Process(target = self.DetachUE_common, args = (device_id,cnt,)) p.daemon = True p.start() multi_jobs.append(p) @@ -1453,11 +1521,14 @@ class SSHConnection(): job.join() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) - def DataDisableUE_common(self, device_id): + def DataDisableUE_common(self, device_id, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) - # enable data service - self.command('stdbuf -o0 adb -s ' + device_id + ' shell svc data disable', '\$', 60) + # disable data service + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "svc data disable"', '\$', 60) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "svc data disable"\'', '\$', 60) logging.debug('\u001B[1mUE (' + device_id + ') Disabled Data Service\u001B[0m') self.close() except: @@ -1468,20 +1539,25 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') multi_jobs = [] + i = 0 for device_id in self.UEDevices: - p = Process(target = self.DataDisableUE_common, args = (device_id,)) + p = Process(target = self.DataDisableUE_common, args = (device_id,i,)) p.daemon = True p.start() multi_jobs.append(p) + i += 1 for job in multi_jobs: job.join() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) - def DataEnableUE_common(self, device_id): + def DataEnableUE_common(self, device_id, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) # enable data service - self.command('stdbuf -o0 adb -s ' + device_id + ' shell svc data enable', '\$', 60) + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "svc data enable"', '\$', 60) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "svc data enable"\'', '\$', 60) logging.debug('\u001B[1mUE (' + device_id + ') Enabled Data Service\u001B[0m') self.close() except: @@ -1492,11 +1568,13 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') multi_jobs = [] + i = 0 for device_id in self.UEDevices: - p = Process(target = self.DataEnableUE_common, args = (device_id,)) + p = Process(target = self.DataEnableUE_common, args = (device_id,i,)) p.daemon = True p.start() multi_jobs.append(p) + i += 1 for job in multi_jobs: job.join() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) @@ -1506,8 +1584,33 @@ class SSHConnection(): Usage() sys.exit('Insufficient Parameter') self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) - self.command('adb devices', '\$', 15) - self.UEDevices = re.findall("\\\\r\\\\n([A-Za-z0-9]+)\\\\tdevice",str(self.ssh.before)) + if self.ADBCentralized: + self.command('adb devices', '\$', 15) + self.UEDevices = re.findall("\\\\r\\\\n([A-Za-z0-9]+)\\\\tdevice",str(self.ssh.before)) + self.close() + else: + if (os.path.isfile('./phones_list.txt')): + os.remove('./phones_list.txt') + self.command('ls /etc/*/phones*.txt', '\$', 5) + result = re.search('/etc/ci/phones_list.txt', str(self.ssh.before)) + self.close() + if (result is not None) and (len(self.UEDevices) == 0): + self.copyin(self.ADBIPAddress, self.ADBUserName, self.ADBPassword, '/etc/ci/phones_list.txt', '.') + if (os.path.isfile('./phones_list.txt')): + phone_list_file = open('./phones_list.txt', 'r') + for line in phone_list_file.readlines(): + line = line.strip() + result = re.search('^#', line) + if result is not None: + continue + comma_split = line.split(",") + self.UEDevices.append(comma_split[0]) + self.UEDevicesRemoteServer.append(comma_split[1]) + self.UEDevicesRemoteUser.append(comma_split[2]) + self.UEDevicesOffCmd.append(comma_split[3]) + self.UEDevicesOnCmd.append(comma_split[4]) + phone_list_file.close() + if terminate_ue_flag == False: if len(self.UEDevices) == 0: logging.debug('\u001B[1;37;41m UE Not Found! \u001B[0m') @@ -1517,25 +1620,36 @@ class SSHConnection(): while cnt < len(self.UEDevices): self.UEDevicesStatus.append(UE_STATUS_DETACHED) cnt += 1 - self.close() def GetAllCatMDevices(self, terminate_ue_flag): if self.ADBIPAddress == '' or self.ADBUserName == '' or self.ADBPassword == '': Usage() sys.exit('Insufficient Parameter') self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) - self.command('lsusb | egrep "Future Technology Devices International, Ltd FT2232C" | sed -e "s#:.*##" -e "s# #_#g"', '\$', 15) - self.CatMDevices = re.findall("\\\\r\\\\n([A-Za-z0-9_]+)",str(self.ssh.before)) + if self.ADBCentralized: + self.command('lsusb | egrep "Future Technology Devices International, Ltd FT2232C" | sed -e "s#:.*##" -e "s# #_#g"', '\$', 15) + self.CatMDevices = re.findall("\\\\r\\\\n([A-Za-z0-9_]+)",str(self.ssh.before)) + else: + if (os.path.isfile('./modules_list.txt')): + os.remove('./modules_list.txt') + self.command('ls /etc/*/modules*.txt', '\$', 5) + result = re.search('/etc/ci/modules_list.txt', str(self.ssh.before)) + self.close() + if result is not None: + logging.debug('Found a module list file on ADB server') if terminate_ue_flag == False: if len(self.CatMDevices) == 0: logging.debug('\u001B[1;37;41m CAT-M UE Not Found! \u001B[0m') sys.exit(1) self.close() - def CheckUEStatus_common(self, lock, device_id, statusQueue): + def CheckUEStatus_common(self, lock, device_id, statusQueue, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) - self.command('stdbuf -o0 adb -s ' + device_id + ' shell dumpsys telephony.registry', '\$', 15) + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "dumpsys telephony.registry"', '\$', 15) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "dumpsys telephony.registry"\'', '\$', 60) result = re.search('mServiceState=(?P<serviceState>[0-9]+)', str(self.ssh.before)) serviceState = 'Service State: UNKNOWN' if result is not None: @@ -1592,11 +1706,13 @@ class SSHConnection(): multi_jobs = [] lock = Lock() status_queue = SimpleQueue() + i = 0 for device_id in self.UEDevices: - p = Process(target = self.CheckUEStatus_common, args = (lock,device_id,status_queue,)) + p = Process(target = self.CheckUEStatus_common, args = (lock,device_id,status_queue,i,)) p.daemon = True p.start() multi_jobs.append(p) + i += 1 for job in multi_jobs: job.join() if self.flexranCtrlInstalled and self.flexranCtrlStarted: @@ -1652,7 +1768,7 @@ class SSHConnection(): sys.exit('Insufficient Parameter') self.open(self.UEIPAddress, self.UEUserName, self.UEPassword) self.command('ifconfig oaitun_ue1', '\$', 4) - result = re.search('inet addr:(?P<ueipaddress>[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)', str(self.ssh.before)) + result = re.search('inet addr:(?P<ueipaddress>[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)|inet (?P<ueipaddress>[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)', str(self.ssh.before)) if result is not None: UE_IPAddress = result.group('ueipaddress') logging.debug('\u001B[1mUE (' + self.UEDevices[0] + ') IP Address is ' + UE_IPAddress + '\u001B[0m') @@ -1670,7 +1786,10 @@ class SSHConnection(): continue count = 0 while count < 4: - self.command('stdbuf -o0 adb -s ' + device_id + ' shell ip addr show | grep rmnet', '\$', 15) + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "ip addr show | grep rmnet"', '\$', 15) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "ip addr show | grep rmnet"\'', '\$', 60) result = re.search('inet (?P<ueipaddress>[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)\/[0-9]+[0-9a-zA-Z\.\s]+', str(self.ssh.before)) if result is None: logging.debug('\u001B[1;37;41m UE IP Address Not Found! \u001B[0m') @@ -2288,7 +2407,10 @@ class SSHConnection(): self.command('if [ ! -d ' + self.EPCSourceCodePath + '/scripts ]; then mkdir -p ' + self.EPCSourceCodePath + '/scripts ; fi', '\$', 5) self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) # Checking if iperf / iperf3 are installed - self.command('adb -s ' + device_id + ' shell "ls /data/local/tmp"', '\$', 5) + if self.ADBCentralized: + self.command('adb -s ' + device_id + ' shell "ls /data/local/tmp"', '\$', 5) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "ls /data/local/tmp"\'', '\$', 60) result = re.search('iperf3', str(self.ssh.before)) if result is None: result = re.search('iperf', str(self.ssh.before)) @@ -2673,10 +2795,14 @@ class SSHConnection(): try: self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) self.command('stdbuf -o0 ps -aux | grep --color=never hss | grep -v grep', '\$', 5) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + result = re.search('oai_hss -j', str(self.ssh.before)) + elif re.match('OAI', self.EPCType, re.IGNORECASE): result = re.search('\/bin\/bash .\/run_', str(self.ssh.before)) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): result = re.search('hss_sim s6as diam_hss', str(self.ssh.before)) + else: + logging.error('This should not happen!') if result is None: logging.debug('\u001B[1;37;41m HSS Process Not Found! \u001B[0m') status_queue.put(HSS_PROCESS_FAILED) @@ -2690,10 +2816,14 @@ class SSHConnection(): try: self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) self.command('stdbuf -o0 ps -aux | grep --color=never mme | grep -v grep', '\$', 5) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + result = re.search('mme -c', str(self.ssh.before)) + elif re.match('OAI', self.EPCType, re.IGNORECASE): result = re.search('\/bin\/bash .\/run_', str(self.ssh.before)) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): result = re.search('mme', str(self.ssh.before)) + else: + logging.error('This should not happen!') if result is None: logging.debug('\u001B[1;37;41m MME Process Not Found! \u001B[0m') status_queue.put(MME_PROCESS_FAILED) @@ -2706,12 +2836,17 @@ class SSHConnection(): def CheckSPGWProcess(self, status_queue): try: self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + self.command('stdbuf -o0 ps -aux | grep --color=never spgw | grep -v grep', '\$', 5) + result = re.search('spgwu -c ', str(self.ssh.before)) + elif re.match('OAI', self.EPCType, re.IGNORECASE): self.command('stdbuf -o0 ps -aux | grep --color=never spgw | grep -v grep', '\$', 5) result = re.search('\/bin\/bash .\/run_', str(self.ssh.before)) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('stdbuf -o0 ps -aux | grep --color=never xGw | grep -v grep', '\$', 5) result = re.search('xGw', str(self.ssh.before)) + else: + logging.error('This should not happen!') if result is None: logging.debug('\u001B[1;37;41m SPGW Process Not Found! \u001B[0m') status_queue.put(SPGW_PROCESS_FAILED) @@ -3153,12 +3288,12 @@ class SSHConnection(): if result is not None: self.command('echo ' + lPassWord + ' | sudo -S daemon --name=enb' + str(self.eNB_instance) + '_daemon --stop', '\$', 5) self.command('echo ' + lPassWord + ' | sudo -S killall --signal SIGINT lte-softmodem || true', '\$', 5) - time.sleep(5) + time.sleep(10) self.command('stdbuf -o0 ps -aux | grep --color=never softmodem | grep -v grep', '\$', 5) result = re.search('lte-softmodem', str(self.ssh.before)) if result is not None: self.command('echo ' + lPassWord + ' | sudo -S killall --signal SIGKILL lte-softmodem || true', '\$', 5) - time.sleep(2) + time.sleep(5) self.command('rm -f my-lte-softmodem-run' + str(self.eNB_instance) + '.sh', '\$', 5) self.close() # If tracer options is on, stopping tshark on EPC side @@ -3218,49 +3353,72 @@ class SSHConnection(): def TerminateHSS(self): self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGINT oai_hss || true', '\$', 5) + time.sleep(2) + self.command('stdbuf -o0 ps -aux | grep hss | grep -v grep', '\$', 5) + result = re.search('oai_hss -j', str(self.ssh.before)) + if result is not None: + self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGKILL oai_hss || true', '\$', 5) + self.command('rm -f ' + self.EPCSourceCodePath + '/scripts/my-hss.sh', '\$', 5) + elif re.match('OAI', self.EPCType, re.IGNORECASE): self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGINT run_hss oai_hss || true', '\$', 5) time.sleep(2) self.command('stdbuf -o0 ps -aux | grep hss | grep -v grep', '\$', 5) result = re.search('\/bin\/bash .\/run_', str(self.ssh.before)) if result is not None: self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGKILL run_hss oai_hss || true', '\$', 5) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cd ' + self.EPCSourceCodePath, '\$', 5) self.command('cd scripts', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S daemon --name=simulated_hss --stop', '\$', 5) time.sleep(1) self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGKILL hss_sim', '\$', 5) + else: + logging.error('This should not happen!') self.close() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) def TerminateMME(self): self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI', self.EPCType, re.IGNORECASE) or re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGINT run_mme mme || true', '\$', 5) time.sleep(2) self.command('stdbuf -o0 ps -aux | grep mme | grep -v grep', '\$', 5) - result = re.search('\/bin\/bash .\/run_', str(self.ssh.before)) + result = re.search('mme -c', str(self.ssh.before)) if result is not None: self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGKILL run_mme mme || true', '\$', 5) - else: + self.command('rm -f ' + self.EPCSourceCodePath + '/scripts/my-mme.sh', '\$', 5) + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cd /opt/ltebox/tools', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S ./stop_mme', '\$', 5) + else: + logging.error('This should not happen!') self.close() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) def TerminateSPGW(self): self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGINT spgwc spgwu || true', '\$', 5) + time.sleep(2) + self.command('stdbuf -o0 ps -aux | grep spgw | grep -v grep', '\$', 5) + result = re.search('spgwc -c |spgwu -c ', str(self.ssh.before)) + if result is not None: + self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGKILL spgwc spgwu || true', '\$', 5) + self.command('rm -f ' + self.EPCSourceCodePath + '/scripts/my-spgw*.sh', '\$', 5) + elif re.match('OAI', self.EPCType, re.IGNORECASE): self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGINT run_spgw spgw || true', '\$', 5) time.sleep(2) self.command('stdbuf -o0 ps -aux | grep spgw | grep -v grep', '\$', 5) result = re.search('\/bin\/bash .\/run_', str(self.ssh.before)) if result is not None: self.command('echo ' + self.EPCPassword + ' | sudo -S killall --signal SIGKILL run_spgw spgw || true', '\$', 5) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cd /opt/ltebox/tools', '\$', 5) self.command('echo ' + self.EPCPassword + ' | sudo -S ./stop_xGw', '\$', 5) + else: + logging.error('This should not happen!') self.close() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) @@ -3279,18 +3437,30 @@ class SSHConnection(): self.flexranCtrlStarted = False self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) - def TerminateUE_common(self, device_id): + def TerminateUE_common(self, device_id, idx): try: self.open(self.ADBIPAddress, self.ADBUserName, self.ADBPassword) # back in airplane mode on (ie radio off) - self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/off', '\$', 60) + if self.ADBCentralized: + if device_id == '84B7N16418004022': + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "su - root -c /data/local/tmp/off"', '\$', 60) + else: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell /data/local/tmp/off', '\$', 60) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' ' + self.UEDevicesOffCmd[idx], '\$', 60) logging.debug('\u001B[1mUE (' + device_id + ') Detach Completed\u001B[0m') - self.command('stdbuf -o0 adb -s ' + device_id + ' shell ps | grep --color=never iperf | grep -v grep', '\$', 5) + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "ps | grep --color=never iperf | grep -v grep"', '\$', 5) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "ps | grep --color=never iperf | grep -v grep"\'', '\$', 60) result = re.search('shell +(?P<pid>\d+)', str(self.ssh.before)) if result is not None: pid_iperf = result.group('pid') - self.command('stdbuf -o0 adb -s ' + device_id + ' shell kill -KILL ' + pid_iperf, '\$', 5) + if self.ADBCentralized: + self.command('stdbuf -o0 adb -s ' + device_id + ' shell "kill -KILL ' + pid_iperf + '"', '\$', 5) + else: + self.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "kill -KILL ' + pid_iperf + '"\'', '\$', 60) self.close() except: os.kill(os.getppid(),signal.SIGUSR1) @@ -3299,11 +3469,13 @@ class SSHConnection(): terminate_ue_flag = True self.GetAllUEDevices(terminate_ue_flag) multi_jobs = [] + i = 0 for device_id in self.UEDevices: - p = Process(target= SSH.TerminateUE_common, args = (device_id,)) + p = Process(target= SSH.TerminateUE_common, args = (device_id,i,)) p.daemon = True p.start() multi_jobs.append(p) + i += 1 for job in multi_jobs: job.join() self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) @@ -3316,12 +3488,12 @@ class SSHConnection(): if result is not None: self.command('echo ' + self.UEPassword + ' | sudo -S daemon --name=ue' + str(self.UE_instance) + '_daemon --stop', '\$', 5) self.command('echo ' + self.UEPassword + ' | sudo -S killall --signal SIGINT lte-uesoftmodem || true', '\$', 5) - time.sleep(5) + time.sleep(10) self.command('ps -aux | grep --color=never softmodem | grep -v grep', '\$', 5) result = re.search('lte-uesoftmodem', str(self.ssh.before)) if result is not None: self.command('echo ' + self.UEPassword + ' | sudo -S killall --signal SIGKILL lte-uesoftmodem || true', '\$', 5) - time.sleep(2) + time.sleep(5) self.command('rm -f my-lte-uesoftmodem-run' + str(self.UE_instance) + '.sh', '\$', 5) self.close() result = re.search('ue_', str(self.UELogFile)) @@ -3544,41 +3716,47 @@ class SSHConnection(): def LogCollectHSS(self): self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - self.command('cd ' + self.EPCSourceCodePath, '\$', 5) - self.command('cd scripts', '\$', 5) + self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) self.command('rm -f hss.log.zip', '\$', 5) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI', self.EPCType, re.IGNORECASE) or re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): self.command('zip hss.log.zip hss*.log', '\$', 60) self.command('rm hss*.log', '\$', 5) - else: + if re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): + self.command('zip hss.log.zip logs/hss*.*', '\$', 60) + self.command('rm logs/hss*.*', '\$', 5) + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cp /opt/hss_sim0609/hss.log .', '\$', 60) self.command('zip hss.log.zip hss.log', '\$', 60) + else: + logging.error('This option should not occur!') self.close() def LogCollectMME(self): self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - self.command('cd ' + self.EPCSourceCodePath, '\$', 5) - self.command('cd scripts', '\$', 5) + self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) self.command('rm -f mme.log.zip', '\$', 5) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI', self.EPCType, re.IGNORECASE) or re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): self.command('zip mme.log.zip mme*.log', '\$', 60) self.command('rm mme*.log', '\$', 5) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cp /opt/ltebox/var/log/*Log.0 .', '\$', 5) self.command('zip mme.log.zip mmeLog.0 s1apcLog.0 s1apsLog.0 s11cLog.0 libLog.0 s1apCodecLog.0', '\$', 60) + else: + logging.error('This option should not occur!') self.close() def LogCollectSPGW(self): self.open(self.EPCIPAddress, self.EPCUserName, self.EPCPassword) - self.command('cd ' + self.EPCSourceCodePath, '\$', 5) - self.command('cd scripts', '\$', 5) + self.command('cd ' + self.EPCSourceCodePath + '/scripts', '\$', 5) self.command('rm -f spgw.log.zip', '\$', 5) - if re.match('OAI', self.EPCType, re.IGNORECASE): + if re.match('OAI', self.EPCType, re.IGNORECASE) or re.match('OAI-Rel14-CUPS', self.EPCType, re.IGNORECASE): self.command('zip spgw.log.zip spgw*.log', '\$', 60) self.command('rm spgw*.log', '\$', 5) - else: + elif re.match('ltebox', self.EPCType, re.IGNORECASE): self.command('cp /opt/ltebox/var/log/xGwLog.0 .', '\$', 5) self.command('zip spgw.log.zip xGwLog.0', '\$', 60) + else: + logging.error('This option should not occur!') self.close() def LogCollectOAIUE(self): @@ -3977,9 +4155,9 @@ class SSHConnection(): # Usage() #----------------------------------------------------------- def Usage(): - print('------------------------------------------------------------') + print('----------------------------------------------------------------------------------------------------------------------') print('main.py Ver:' + Version) - print('------------------------------------------------------------') + print('----------------------------------------------------------------------------------------------------------------------') print('Usage: python main.py [options]') print(' --help Show this help.') print(' --mode=[Mode]') @@ -3987,25 +4165,35 @@ def Usage(): print(' InitiateHtml, FinalizeHtml') print(' TerminateeNB, TerminateUE, TerminateHSS, TerminateMME, TerminateSPGW') print(' LogCollectBuild, LogCollecteNB, LogCollectHSS, LogCollectMME, LogCollectSPGW, LogCollectPing, LogCollectIperf') - print(' --eNBRepository=[eNB\'s Repository URL] or --ranRepository=[OAI RAN Repository URL]') - print(' --eNBBranch=[eNB\'s Branch Name] or --ranBranch=[OAI RAN Repository Branch') - print(' --eNBCommitID=[eNB\'s Commit Number] or --ranCommitID=[OAI RAN Repository Commit SHA-1') - print(' --eNB_AllowMerge=[eNB\'s Allow Merge Request (with target branch)] or --ranAllowMerge=true/false') - print(' --eNBTargetBranch=[eNB\'s Target Branch in case of a Merge Request] or --ranTargetBranch=[Target Branch]') + print('---------------------------------------------------------------------------------------------------- Git Options --') + print(' --ranRepository=[OAI RAN Repository URL]') + print(' --ranBranch=[OAI RAN Repository Branch]') + print(' --ranCommitID=[OAI RAN Repository Commit SHA-1]') + print(' --ranAllowMerge=[Allow Merge Request (with target branch) (true or false)]') + print(' --ranTargetBranch=[Target Branch in case of a Merge Request]') + print('--------------------------------------------------------------------------------------------- eNB Server Options --') print(' --eNBIPAddress=[eNB\'s IP Address]') print(' --eNBUserName=[eNB\'s Login User Name]') print(' --eNBPassword=[eNB\'s Login Password]') print(' --eNBSourceCodePath=[eNB\'s Source Code Path]') + print('------------------------------------------------------------------------------------------ OAI UE Server Options --') + print(' --UEIPAddress=[UE\'s IP Address]') + print(' --UEUserName=[UE\'s Login User Name]') + print(' --UEPassword=[UE\'s Login Password]') + print(' --UESourceCodePath=[UE\'s Source Code Path]') + print('--------------------------------------------------------------------------------------------- EPC Server Options --') print(' --EPCIPAddress=[EPC\'s IP Address]') print(' --EPCUserName=[EPC\'s Login User Name]') print(' --EPCPassword=[EPC\'s Login Password]') print(' --EPCSourceCodePath=[EPC\'s Source Code Path]') - print(' --EPCType=[EPC\'s Type: OAI or ltebox]') + print(' --EPCType=[EPC\'s Type: OAI or ltebox or OAI-Rel14-CUPS]') + print('--------------------------------------------------------------------------------------------- ABD Server Options --') print(' --ADBIPAddress=[ADB\'s IP Address]') print(' --ADBUserName=[ADB\'s Login User Name]') print(' --ADBPassword=[ADB\'s Login Password]') + print('----------------------------------------------------------------------------------------------------------------------') print(' --XMLTestFile=[XML Test File to be run]') - print('------------------------------------------------------------') + print('----------------------------------------------------------------------------------------------------------------------') def CheckClassValidity(action,id): if action != 'Build_eNB' and action != 'WaitEndBuild_eNB' and action != 'Initialize_eNB' and action != 'Terminate_eNB' and action != 'Initialize_UE' and action != 'Terminate_UE' and action != 'Attach_UE' and action != 'Detach_UE' and action != 'Build_OAI_UE' and action != 'Initialize_OAI_UE' and action != 'Terminate_OAI_UE' and action != 'DataDisable_UE' and action != 'DataEnable_UE' and action != 'CheckStatusUE' and action != 'Ping' and action != 'Iperf' and action != 'Reboot_UE' and action != 'Initialize_FlexranCtrl' and action != 'Terminate_FlexranCtrl' and action != 'Initialize_HSS' and action != 'Terminate_HSS' and action != 'Initialize_MME' and action != 'Terminate_MME' and action != 'Initialize_SPGW' and action != 'Terminate_SPGW' and action != 'Initialize_CatM_module' and action != 'Terminate_CatM_module' and action != 'Attach_CatM_module' and action != 'Detach_CatM_module' and action != 'Ping_CatM_module' and action != 'IdleSleep' and action != 'Perform_X2_Handover': @@ -4238,16 +4426,25 @@ while len(argvs) > 1: SSH.EPCSourceCodePath = matchReg.group(1) elif re.match('^\-\-EPCType=(.+)$', myArgv, re.IGNORECASE): matchReg = re.match('^\-\-EPCType=(.+)$', myArgv, re.IGNORECASE) - if re.match('OAI', matchReg.group(1), re.IGNORECASE) or re.match('ltebox', matchReg.group(1), re.IGNORECASE): + if re.match('OAI', matchReg.group(1), re.IGNORECASE) or re.match('ltebox', matchReg.group(1), re.IGNORECASE) or re.match('OAI-Rel14-CUPS', matchReg.group(1), re.IGNORECASE): SSH.EPCType = matchReg.group(1) else: - sys.exit('Invalid EPC Type: ' + matchReg.group(1) + ' -- (should be OAI or ltebox)') + sys.exit('Invalid EPC Type: ' + matchReg.group(1) + ' -- (should be OAI or ltebox or OAI-Rel14-CUPS)') elif re.match('^\-\-ADBIPAddress=(.+)$', myArgv, re.IGNORECASE): matchReg = re.match('^\-\-ADBIPAddress=(.+)$', myArgv, re.IGNORECASE) SSH.ADBIPAddress = matchReg.group(1) elif re.match('^\-\-ADBUserName=(.+)$', myArgv, re.IGNORECASE): matchReg = re.match('^\-\-ADBUserName=(.+)$', myArgv, re.IGNORECASE) SSH.ADBUserName = matchReg.group(1) + elif re.match('^\-\-ADBType=(.+)$', myArgv, re.IGNORECASE): + matchReg = re.match('^\-\-ADBType=(.+)$', myArgv, re.IGNORECASE) + if re.match('centralized', matchReg.group(1), re.IGNORECASE) or re.match('distributed', matchReg.group(1), re.IGNORECASE): + if re.match('distributed', matchReg.group(1), re.IGNORECASE): + SSH.ADBCentralized = False + else: + SSH.ADBCentralized = True + else: + sys.exit('Invalid ADB Type: ' + matchReg.group(1) + ' -- (should be centralized or distributed)') elif re.match('^\-\-ADBPassword=(.+)$', myArgv, re.IGNORECASE): matchReg = re.match('^\-\-ADBPassword=(.+)$', myArgv, re.IGNORECASE) SSH.ADBPassword = matchReg.group(1) diff --git a/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_epc_start.xml b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_epc_start.xml new file mode 100644 index 0000000000000000000000000000000000000000..ed41e8b977065bbd90e1e6aed03e935ffe54aa6f --- /dev/null +++ b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_epc_start.xml @@ -0,0 +1,53 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>build-tab</htmlTabRef> + <htmlTabName>Build</htmlTabName> + <htmlTabIcon>log-in</htmlTabIcon> + <TestCaseRequestedList> + 050101 000001 060101 000001 070101 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="000001"> + <class>IdleSleep</class> + <desc>Sleep</desc> + <idle_sleep_time_in_sec>20</idle_sleep_time_in_sec> + </testCase> + + <testCase id="050101"> + <class>Initialize_HSS</class> + <desc>Initialize HSS</desc> + </testCase> + + <testCase id="060101"> + <class>Initialize_MME</class> + <desc>Initialize MME</desc> + </testCase> + + <testCase id="070101"> + <class>Initialize_SPGW</class> + <desc>Initialize SPGW</desc> + </testCase> + +</testCaseList> diff --git a/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_epc_stop.xml b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_epc_stop.xml new file mode 100644 index 0000000000000000000000000000000000000000..07fb6951f8e99a35cabd2ee4e48232d2bd035f41 --- /dev/null +++ b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_epc_stop.xml @@ -0,0 +1,47 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>epc-closure</htmlTabRef> + <htmlTabName>EPC-Closure</htmlTabName> + <htmlTabIcon>log-out</htmlTabIcon> + <TestCaseRequestedList> + 050201 060201 070201 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="050201"> + <class>Terminate_HSS</class> + <desc>Terminate HSS</desc> + </testCase> + + <testCase id="060201"> + <class>Terminate_MME</class> + <desc>Terminate MME</desc> + </testCase> + + <testCase id="070201"> + <class>Terminate_SPGW</class> + <desc>Terminate SPGW</desc> + </testCase> + +</testCaseList> diff --git a/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_terminate.xml b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_terminate.xml new file mode 100644 index 0000000000000000000000000000000000000000..962aec41295093aaf4c7c1d9aa7d545a83a7b7d6 --- /dev/null +++ b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_terminate.xml @@ -0,0 +1,42 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>terminate-enb-oai-ue</htmlTabRef> + <htmlTabName>Terminate-all-eNBs-OAI-UEs</htmlTabName> + <htmlTabIcon>tasks</htmlTabIcon> + <TestCaseRequestedList> + 030201 090109 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="030201"> + <class>Terminate_eNB</class> + <desc>Terminate eNB</desc> + </testCase> + + <testCase id="090109"> + <class>Terminate_OAI_UE</class> + <desc>Terminate OAI UE</desc> + </testCase> + +</testCaseList> diff --git a/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_test_05mhz_tm1.xml b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_test_05mhz_tm1.xml new file mode 100644 index 0000000000000000000000000000000000000000..24cc94a81034e48a11b4631d994b45d9ca2eaa26 --- /dev/null +++ b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_test_05mhz_tm1.xml @@ -0,0 +1,68 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>test-05-tm1</htmlTabRef> + <htmlTabName>Test-05MHz-TM1</htmlTabName> + <htmlTabIcon>tasks</htmlTabIcon> + <repeatCount>4</repeatCount> + <TestCaseRequestedList> + 030201 090109 + 030102 000001 090102 000002 090109 000001 030201 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="000001"> + <class>IdleSleep</class> + <desc>Sleep for 10 sec</desc> + <idle_sleep_time_in_sec>10</idle_sleep_time_in_sec> + </testCase> + + <testCase id="000002"> + <class>IdleSleep</class> + <desc>Sleep for 30 sec</desc> + <idle_sleep_time_in_sec>30</idle_sleep_time_in_sec> + </testCase> + + <testCase id="030102"> + <class>Initialize_eNB</class> + <desc>Initialize eNB (FDD/Band7/5MHz)</desc> + <Initialize_eNB_args>-O ci-scripts/conf_files/enb.band7.tm1.25PRB.usrpb210.conf --eNBs.[0].rrc_inactivity_threshold 0 --RUs.[0].max_rxgain 120 --eNBs.[0].component_carriers.[0].pusch_p0_Nominal -90 --eNBs.[0].component_carriers.[0].pucch_p0_Nominal -96 --eNBs.[0].tracking_area_code 600 --eNBs.[0].plmn_list.[0].mnc 95 --THREAD_STRUCT.[0].parallel_config PARALLEL_RU_L1_TRX_SPLIT</Initialize_eNB_args> + </testCase> + + <testCase id="030201"> + <class>Terminate_eNB</class> + <desc>Terminate eNB</desc> + </testCase> + + <testCase id="090102"> + <class>Initialize_OAI_UE</class> + <desc>Initialize OAI UE (FDD/Band7/5MHz)</desc> + <Initialize_OAI_UE_args>-C 2680000000 -r 25 --ue-rxgain 130 --ue-txgain 1 --ue-max-power -6 --ue-scan-carrier --nokrnmod 1</Initialize_OAI_UE_args> + </testCase> + + <testCase id="090109"> + <class>Terminate_OAI_UE</class> + <desc>Terminate OAI UE</desc> + </testCase> + +</testCaseList> diff --git a/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_test_05mhz_tm1_nos1.xml b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_test_05mhz_tm1_nos1.xml new file mode 100644 index 0000000000000000000000000000000000000000..dff0761bd392acc7647889e517f2593a78d2039c --- /dev/null +++ b/ci-scripts/xml_files/inria/enb_ue_usrp210_band7_test_05mhz_tm1_nos1.xml @@ -0,0 +1,118 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>test-05-tm1-nos1-tunnel</htmlTabRef> + <htmlTabName>Test-05MHz-TM1-noS1-tunnel</htmlTabName> + <htmlTabIcon>tasks</htmlTabIcon> + <repeatCount>2</repeatCount> + <TestCaseRequestedList> + 030201 090109 + 030101 000001 090101 000002 040501 040502 000001 040601 040602 040641 040642 000001 090109 030201 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="000001"> + <class>IdleSleep</class> + <desc>Sleep</desc> + <idle_sleep_time_in_sec>10</idle_sleep_time_in_sec> + </testCase> + + <testCase id="000002"> + <class>IdleSleep</class> + <desc>Sleep</desc> + <idle_sleep_time_in_sec>5</idle_sleep_time_in_sec> + </testCase> + + <testCase id="000003"> + <class>IdleSleep</class> + <desc>Sleep</desc> + <idle_sleep_time_in_sec>60</idle_sleep_time_in_sec> + </testCase> + + <testCase id="030101"> + <class>Initialize_eNB</class> + <desc>Initialize eNB (FDD/Band7/5MHz)</desc> + <Initialize_eNB_args>-O ci-scripts/conf_files/enb.band7.tm1.25PRB.usrpb210.conf --noS1 --eNBs.[0].rrc_inactivity_threshold 0 --RUs.[0].max_rxgain 120 --eNBs.[0].component_carriers.[0].pusch_p0_Nominal -90 --eNBs.[0].component_carriers.[0].pucch_p0_Nominal -96 --eNBs.[0].tracking_area_code 600 --eNBs.[0].plmn_list.[0].mnc 95 --THREAD_STRUCT.[0].parallel_config PARALLEL_RU_L1_TRX_SPLIT</Initialize_eNB_args> + </testCase> + + <testCase id="030201"> + <class>Terminate_eNB</class> + <desc>Terminate eNB</desc> + </testCase> + + <testCase id="090101"> + <class>Initialize_OAI_UE</class> + <desc>Initialize OAI UE (FDD/Band7/5MHz)</desc> + <Initialize_OAI_UE_args>-C 2680000000 -r 25 --ue-rxgain 130 --ue-txgain 1 --ue-max-power -6 --ue-scan-carrier --nokrnmod 1 --noS1</Initialize_OAI_UE_args> + </testCase> + + <testCase id="090109"> + <class>Terminate_OAI_UE</class> + <desc>Terminate OAI UE</desc> + </testCase> + + <testCase id="040501"> + <class>Ping</class> + <desc>ping (5MHz - 20 sec)(from eNB to OAI UE)</desc> + <ping_args>-I oaitun_enb1 -c 20 10.0.1.2</ping_args> + <ping_packetloss_threshold>5</ping_packetloss_threshold> + </testCase> + + <testCase id="040502"> + <class>Ping</class> + <desc>ping (5MHz - 20 sec)(from OAI UE to eNB)</desc> + <ping_args>-I oaitun_ue1 -c 20 10.0.1.1</ping_args> + <ping_packetloss_threshold>5</ping_packetloss_threshold> + </testCase> + + <testCase id="040601"> + <class>Iperf</class> + <desc>iperf (5MHz - DL/1Mbps/UDP)(30 sec)</desc> + <iperf_args>-c 10.0.1.2 -u -b 1M -t 30 -i 1 -fm -B 10.0.1.1</iperf_args> + <iperf_packetloss_threshold>50</iperf_packetloss_threshold> + </testCase> + + <testCase id="040602"> + <class>Iperf</class> + <desc>iperf (5MHz - DL/10Mbps/UDP)(30 sec)</desc> + <iperf_args>-c 10.0.1.2 -u -b 10M -t 30 -i 1 -fm -B 10.0.1.1</iperf_args> + <iperf_packetloss_threshold>50</iperf_packetloss_threshold> + </testCase> + + <testCase id="040641"> + <class>Iperf</class> + <desc>iperf (5MHz - UL/1Mbps/UDP)(30 sec)</desc> + <iperf_args>-c 10.0.1.1 -u -b 1M -t 30 -i 1 -fm -B 10.0.1.2 -R</iperf_args> + <iperf_packetloss_threshold>50</iperf_packetloss_threshold> + <iperf_profile>balanced</iperf_profile> + </testCase> + + <testCase id="040642"> + <class>Iperf</class> + <desc>iperf (5MHz - UL/2Mbps/UDP)(30 sec)</desc> + <iperf_args>-c 10.0.1.1 -u -b 2M -t 30 -i 1 -fm -B 10.0.1.2 -R</iperf_args> + <iperf_packetloss_threshold>50</iperf_packetloss_threshold> + <iperf_profile>balanced</iperf_profile> + </testCase> + +</testCaseList> diff --git a/ci-scripts/xml_files/inria/enb_usrp210_band7_build.xml b/ci-scripts/xml_files/inria/enb_usrp210_band7_build.xml new file mode 100644 index 0000000000000000000000000000000000000000..c1ba7359b31e0c917de897cf64b17345aed209a6 --- /dev/null +++ b/ci-scripts/xml_files/inria/enb_usrp210_band7_build.xml @@ -0,0 +1,58 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>build-tab-enb0</htmlTabRef> + <htmlTabName>Build eNB0</htmlTabName> + <htmlTabIcon>wrench</htmlTabIcon> + <TestCaseRequestedList> + 010101 040101 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="010101"> + <class>Build_eNB</class> + <desc>Build eNB (USRP)</desc> + <Build_eNB_args>-w USRP -c --eNB</Build_eNB_args> + </testCase> + + <testCase id="050101"> + <class>Initialize_HSS</class> + <desc>Initialize HSS</desc> + </testCase> + + <testCase id="060101"> + <class>Initialize_MME</class> + <desc>Initialize MME</desc> + </testCase> + + <testCase id="070101"> + <class>Initialize_SPGW</class> + <desc>Initialize SPGW</desc> + </testCase> + + <testCase id="040101"> + <class>Initialize_UE</class> + <desc>Initialize UE</desc> + </testCase> + +</testCaseList> diff --git a/ci-scripts/xml_files/inria/ue_band7_build.xml b/ci-scripts/xml_files/inria/ue_band7_build.xml new file mode 100644 index 0000000000000000000000000000000000000000..7d7ae6e0df4624a7929048eb56120d2e0d7d6133 --- /dev/null +++ b/ci-scripts/xml_files/inria/ue_band7_build.xml @@ -0,0 +1,38 @@ +<!-- + + Licensed to the OpenAirInterface (OAI) Software Alliance under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The OpenAirInterface Software Alliance licenses this file to You under + the OAI Public License, Version 1.1 (the "License"); you may not use this file + except in compliance with the License. + You may obtain a copy of the License at + + http://www.openairinterface.org/?page_id=698 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + For more information about the OpenAirInterface (OAI) Software Alliance: + contact@openairinterface.org + +--> +<testCaseList> + <htmlTabRef>build-tab-ue0</htmlTabRef> + <htmlTabName>Build UE0</htmlTabName> + <htmlTabIcon>wrench</htmlTabIcon> + <TestCaseRequestedList> +090101 + </TestCaseRequestedList> + <TestCaseExclusionList></TestCaseExclusionList> + + <testCase id="090101"> + <class>Build_OAI_UE</class> + <desc>Build OAI UE</desc> + <Build_OAI_UE_args>-w USRP --UE</Build_OAI_UE_args> + </testCase> + +</testCaseList>