Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
spbro
OpenXG-RAN
Commits
08353293
Commit
08353293
authored
Mar 21, 2024
by
Jaroslava Fiedlerova
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename and modify ci_ueinfra and cls_module_ue
- add traffic servers - add runServer parameter
parent
921c24ce
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
52 additions
and
13 deletions
+52
-13
ci-scripts/ci_infra.yaml
ci-scripts/ci_infra.yaml
+33
-0
ci-scripts/cls_module.py
ci-scripts/cls_module.py
+6
-2
ci-scripts/cls_oaicitest.py
ci-scripts/cls_oaicitest.py
+12
-10
ci-scripts/main.py
ci-scripts/main.py
+1
-1
No files found.
ci-scripts/ci_
ue
infra.yaml
→
ci-scripts/ci_infra.yaml
View file @
08353293
...
...
@@ -56,6 +56,39 @@ adb_ue_2:
MTU
:
1500
LogStore
:
/media/usb-drive/ci_adb_2-logs
oc-cn5g
:
Host
:
avra
NetworkScript
:
echo "inet 172.21.6.102"
RunIperf3Server
:
False
porcepix-cn4g
:
Host
:
porcepix
NetworkScript
:
docker exec prod-trf-gen ip a show dev eth0
CmdPrefix
:
docker exec prod-trf-gen
porcepix-cn5g
:
Host
:
porcepix
NetworkScript
:
docker exec prod-trf-gen ip a show dev eth0
CmdPrefix
:
docker exec prod-trf-gen
RunIperf3Server
:
False
nano-cn4g
:
Host
:
nano
NetworkScript
:
docker exec prod-trf-gen ip a show dev eth0
CmdPrefix
:
docker exec prod-trf-gen
ltebox-nano
:
Host
:
nano
NetworkScript
:
ip a show dev tun1
sabox-nepes
:
Host
:
nepes
NetworkScript
:
ip a show dev tun1
ltebox-nepes
:
Host
:
nepes
NetworkScript
:
ip a show dev tun1
amarisoft_ue
:
Host
:
amariue
InitScript
:
/root/lteue-linux-2023-10-27/ue/lteue /root/oaicicd/ran_sa_aw2s_asue_2x2/aw2s-multi-20897-2x2.cfg &
...
...
ci-scripts/cls_module
_ue
.py
→
ci-scripts/cls_module.py
View file @
08353293
...
...
@@ -41,7 +41,7 @@ import cls_cmd
class
Module_UE
:
def
__init__
(
self
,
module_name
,
filename
=
"ci_
ue
infra.yaml"
):
def
__init__
(
self
,
module_name
,
filename
=
"ci_infra.yaml"
):
with
open
(
filename
,
'r'
)
as
f
:
all_ues
=
yaml
.
load
(
f
,
Loader
=
yaml
.
FullLoader
)
m
=
all_ues
.
get
(
module_name
)
...
...
@@ -64,7 +64,8 @@ class Module_UE:
self
.
trace
=
m
.
get
(
'trace'
)
==
True
self
.
logStore
=
m
.
get
(
'LogStore'
)
self
.
cmd_prefix
=
m
.
get
(
'CmdPrefix'
)
logging
.
info
(
f'initialized UE
{
self
.
module_name
}
@
{
self
.
host
}
from
{
filename
}
'
)
self
.
runIperf3Server
=
m
.
get
(
'RunIperf3Server'
,
True
)
logging
.
info
(
f'initialized
{
self
.
module_name
}
@
{
self
.
host
}
from
{
filename
}
'
)
def
__str__
(
self
):
return
f"
{
self
.
module_name
}
@
{
self
.
host
}
[IP:
{
self
.
getIP
()
}
]"
...
...
@@ -189,6 +190,9 @@ class Module_UE:
def
getHost
(
self
):
return
self
.
host
def
getRunIperf3Server
(
self
):
return
self
.
runIperf3Server
def
getCmdPrefix
(
self
):
return
self
.
cmd_prefix
if
self
.
cmd_prefix
else
""
...
...
ci-scripts/cls_oaicitest.py
View file @
08353293
...
...
@@ -52,7 +52,7 @@ import constants as CONST
import
cls_cluster
as
OC
import
sshconnection
import
cls_module
_ue
import
cls_module
import
cls_cmd
logging
.
getLogger
(
"matplotlib"
).
setLevel
(
logging
.
WARNING
)
...
...
@@ -113,6 +113,7 @@ class OaiCiTest():
self
.
clean_repository
=
True
self
.
air_interface
=
''
self
.
ue_ids
=
[]
self
.
svr_id
=
None
self
.
cmd_prefix
=
''
# prefix before {lte,nr}-uesoftmodem
...
...
@@ -222,7 +223,7 @@ class OaiCiTest():
def
InitializeUE
(
self
,
HTML
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
messages
=
[]
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
ue
.
initialize
)
for
ue
in
ues
]
...
...
@@ -438,7 +439,7 @@ class OaiCiTest():
self
.
AutoTerminateUEandeNB
(
HTML
,
RAN
,
EPC
,
CONTAINERS
)
def
AttachUE
(
self
,
HTML
,
RAN
,
EPC
,
CONTAINERS
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
ue
.
attach
)
for
ue
in
ues
]
attached
=
[
f
.
result
()
for
f
in
futures
]
...
...
@@ -453,7 +454,7 @@ class OaiCiTest():
self
.
AutoTerminateUEandeNB
(
HTML
,
RAN
,
EPC
,
CONTAINERS
)
def
DetachUE
(
self
,
HTML
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
ue
.
detach
)
for
ue
in
ues
]
[
f
.
result
()
for
f
in
futures
]
...
...
@@ -461,7 +462,7 @@ class OaiCiTest():
HTML
.
CreateHtmlTestRowQueue
(
'NA'
,
'OK'
,
messages
)
def
DataDisableUE
(
self
,
HTML
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
ue
.
dataDisable
)
for
ue
in
ues
]
status
=
[
f
.
result
()
for
f
in
futures
]
...
...
@@ -473,7 +474,7 @@ class OaiCiTest():
HTML
.
CreateHtmlTestRowQueue
(
'N/A'
,
'KO'
,
[
"Could not disable UE data!"
])
def
DataEnableUE
(
self
,
HTML
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
logging
.
debug
(
f'disabling data for UEs
{
ues
}
'
)
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
ue
.
dataEnable
)
for
ue
in
ues
]
...
...
@@ -486,7 +487,7 @@ class OaiCiTest():
HTML
.
CreateHtmlTestRowQueue
(
'N/A'
,
'KO'
,
[
"Could not enable UE data!"
])
def
CheckStatusUE
(
self
,
HTML
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
logging
.
debug
(
f'checking status of UEs
{
ues
}
'
)
messages
=
[]
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
...
...
@@ -590,7 +591,7 @@ class OaiCiTest():
if
self
.
ue_ids
==
[]:
raise
Exception
(
"no module names in self.ue_ids provided"
)
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
logging
.
debug
(
ues
)
pingLock
=
Lock
()
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
...
...
@@ -990,7 +991,8 @@ class OaiCiTest():
logging
.
debug
(
f'Iperf: iperf_args "
{
self
.
iperf_args
}
" iperf_direction "
{
self
.
iperf_direction
}
" iperf_packetloss_threshold "
{
self
.
iperf_packetloss_threshold
}
" iperf_bitrate_threshold "
{
self
.
iperf_bitrate_threshold
}
" iperf_profile "
{
self
.
iperf_profile
}
" iperf_options "
{
self
.
iperf_options
}
"'
)
ues
=
[
cls_module_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
svr
=
cls_module
.
Module_UE
(
self
.
svr_id
)
logging
.
debug
(
ues
)
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
self
.
Iperf_Module
,
EPC
,
ue
,
RAN
,
i
,
len
(
ues
))
for
i
,
ue
in
enumerate
(
ues
)]
...
...
@@ -1272,7 +1274,7 @@ class OaiCiTest():
return
global_status
def
TerminateUE
(
self
,
HTML
):
ues
=
[
cls_module
_ue
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
ues
=
[
cls_module
.
Module_UE
(
n
.
strip
())
for
n
in
self
.
ue_ids
]
with
concurrent
.
futures
.
ThreadPoolExecutor
()
as
executor
:
futures
=
[
executor
.
submit
(
ue
.
terminate
)
for
ue
in
ues
]
archives
=
[
f
.
result
()
for
f
in
futures
]
...
...
ci-scripts/main.py
View file @
08353293
...
...
@@ -268,7 +268,7 @@ def GetParametersFromXML(action):
elif
action
==
'Iperf'
:
CiTestObj
.
iperf_args
=
test
.
findtext
(
'iperf_args'
)
CiTestObj
.
ue_ids
=
test
.
findtext
(
'id'
).
split
(
' '
)
CiTestObj
.
iperf_direction
=
test
.
findtext
(
'direction'
)
CiTestObj
.
svr_id
=
test
.
findtext
(
'svr_id'
)
or
None
CiTestObj
.
iperf_packetloss_threshold
=
test
.
findtext
(
'iperf_packetloss_threshold'
)
CiTestObj
.
iperf_bitrate_threshold
=
test
.
findtext
(
'iperf_bitrate_threshold'
)
or
'90'
CiTestObj
.
iperf_profile
=
test
.
findtext
(
'iperf_profile'
)
or
'balanced'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment