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
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
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
OpenXG
OpenXG-RAN
Commits
244ea8fc
Commit
244ea8fc
authored
Aug 06, 2025
by
Robert Schmidt
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use archiveArtifact() for TerminateeNB()
parent
5090ce6f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
15 deletions
+19
-15
ci-scripts/main.py
ci-scripts/main.py
+1
-1
ci-scripts/ran.py
ci-scripts/ran.py
+18
-14
No files found.
ci-scripts/main.py
View file @
244ea8fc
...
@@ -206,7 +206,7 @@ def ExecuteActionWithParam(action, ctx):
...
@@ -206,7 +206,7 @@ def ExecuteActionWithParam(action, ctx):
RAN
.
air_interface
[
RAN
.
eNB_instance
]
=
'lte-softmodem'
RAN
.
air_interface
[
RAN
.
eNB_instance
]
=
'lte-softmodem'
else
:
else
:
RAN
.
air_interface
[
RAN
.
eNB_instance
]
=
air_interface
.
lower
()
+
'-softmodem'
RAN
.
air_interface
[
RAN
.
eNB_instance
]
=
air_interface
.
lower
()
+
'-softmodem'
success
=
RAN
.
TerminateeNB
(
HTML
)
success
=
RAN
.
TerminateeNB
(
ctx
,
HTML
)
elif
action
==
'Initialize_UE'
or
action
==
'Attach_UE'
or
action
==
'Detach_UE'
or
action
==
'Terminate_UE'
or
action
==
'CheckStatusUE'
or
action
==
'DataEnable_UE'
or
action
==
'DataDisable_UE'
:
elif
action
==
'Initialize_UE'
or
action
==
'Attach_UE'
or
action
==
'Detach_UE'
or
action
==
'Terminate_UE'
or
action
==
'CheckStatusUE'
or
action
==
'DataEnable_UE'
or
action
==
'DataDisable_UE'
:
CiTestObj
.
ue_ids
=
test
.
findtext
(
'id'
).
split
(
' '
)
CiTestObj
.
ue_ids
=
test
.
findtext
(
'id'
).
split
(
' '
)
...
...
ci-scripts/ran.py
View file @
244ea8fc
...
@@ -46,6 +46,7 @@ import cls_cmd
...
@@ -46,6 +46,7 @@ import cls_cmd
import
sshconnection
as
SSH
import
sshconnection
as
SSH
import
helpreadme
as
HELP
import
helpreadme
as
HELP
import
constants
as
CONST
import
constants
as
CONST
from
cls_ci_helper
import
archiveArtifact
#-----------------------------------------------------------
#-----------------------------------------------------------
# Class Declaration
# Class Declaration
...
@@ -248,7 +249,7 @@ class RANManagement():
...
@@ -248,7 +249,7 @@ class RANManagement():
logging
.
debug
(
'
\u001B
[1m Initialize eNB/gNB Completed
\u001B
[0m'
)
logging
.
debug
(
'
\u001B
[1m Initialize eNB/gNB Completed
\u001B
[0m'
)
return
enbDidSync
return
enbDidSync
def
TerminateeNB
(
self
,
HTML
):
def
TerminateeNB
(
self
,
ctx
,
HTML
):
if
self
.
eNB_serverId
[
self
.
eNB_instance
]
==
'0'
:
if
self
.
eNB_serverId
[
self
.
eNB_instance
]
==
'0'
:
lIpAddr
=
self
.
eNBIPAddress
lIpAddr
=
self
.
eNBIPAddress
lUserName
=
self
.
eNBUserName
lUserName
=
self
.
eNBUserName
...
@@ -320,13 +321,11 @@ class RANManagement():
...
@@ -320,13 +321,11 @@ class RANManagement():
fileToAnalyze
=
self
.
eNBLogFiles
[
int
(
self
.
eNB_instance
)]
fileToAnalyze
=
self
.
eNBLogFiles
[
int
(
self
.
eNB_instance
)]
self
.
eNBLogFiles
[
int
(
self
.
eNB_instance
)]
=
''
self
.
eNBLogFiles
[
int
(
self
.
eNB_instance
)]
=
''
if
analyzeFile
:
if
analyzeFile
:
#*stats.log files + pickle + png
with
cls_cmd
.
getConnection
(
lIpAddr
)
as
cmd
:
mySSH
.
copyin
(
lIpAddr
,
lUserName
,
lPassWord
,
lSourcePath
+
'/cmake_targets/*stats.log'
,
'.'
)
file
=
archiveArtifact
(
cmd
,
ctx
,
lSourcePath
+
'/cmake_targets/'
+
fileToAnalyze
)
mySSH
.
copyin
(
lIpAddr
,
lUserName
,
lPassWord
,
lSourcePath
+
'/cmake_targets/*.pickle'
,
'.'
)
archiveArtifact
(
cmd
,
ctx
,
lSourcePath
+
'/cmake_targets/nrL1_stats.log'
)
mySSH
.
copyin
(
lIpAddr
,
lUserName
,
lPassWord
,
lSourcePath
+
'/cmake_targets/*.png'
,
'.'
)
archiveArtifact
(
cmd
,
ctx
,
lSourcePath
+
'/cmake_targets/nrMAC_stats.log'
)
#
if
file
is
None
:
copyin_res
=
mySSH
.
copyin
(
lIpAddr
,
lUserName
,
lPassWord
,
lSourcePath
+
'/cmake_targets/'
+
fileToAnalyze
,
'.'
)
if
(
copyin_res
==
-
1
):
logging
.
debug
(
'
\u001B
[1;37;41m Could not copy '
+
nodeB_prefix
+
'NB logfile to analyze it!
\u001B
[0m'
)
logging
.
debug
(
'
\u001B
[1;37;41m Could not copy '
+
nodeB_prefix
+
'NB logfile to analyze it!
\u001B
[0m'
)
HTML
.
htmleNBFailureMsg
=
'Could not copy '
+
nodeB_prefix
+
'NB logfile to analyze it!'
HTML
.
htmleNBFailureMsg
=
'Could not copy '
+
nodeB_prefix
+
'NB logfile to analyze it!'
HTML
.
CreateHtmlTestRow
(
'N/A'
,
'KO'
,
CONST
.
ENB_PROCESS_NOLOGFILE_TO_ANALYZE
)
HTML
.
CreateHtmlTestRow
(
'N/A'
,
'KO'
,
CONST
.
ENB_PROCESS_NOLOGFILE_TO_ANALYZE
)
...
@@ -339,8 +338,8 @@ class RANManagement():
...
@@ -339,8 +338,8 @@ class RANManagement():
mySSH
.
copyout
(
self
.
eNBIPAddress
,
self
.
eNBUserName
,
self
.
eNBPassword
,
'./nrL1_stats.log'
,
self
.
eNBSourceCodePath
+
'/cmake_targets/'
)
mySSH
.
copyout
(
self
.
eNBIPAddress
,
self
.
eNBUserName
,
self
.
eNBPassword
,
'./nrL1_stats.log'
,
self
.
eNBSourceCodePath
+
'/cmake_targets/'
)
mySSH
.
copyout
(
self
.
eNBIPAddress
,
self
.
eNBUserName
,
self
.
eNBPassword
,
'./nrMAC_stats.log'
,
self
.
eNBSourceCodePath
+
'/cmake_targets/'
)
mySSH
.
copyout
(
self
.
eNBIPAddress
,
self
.
eNBUserName
,
self
.
eNBPassword
,
'./nrMAC_stats.log'
,
self
.
eNBSourceCodePath
+
'/cmake_targets/'
)
mySSH
.
copyout
(
self
.
eNBIPAddress
,
self
.
eNBUserName
,
self
.
eNBPassword
,
'./'
+
fileToAnalyze
,
self
.
eNBSourceCodePath
+
'/cmake_targets/'
)
mySSH
.
copyout
(
self
.
eNBIPAddress
,
self
.
eNBUserName
,
self
.
eNBPassword
,
'./'
+
fileToAnalyze
,
self
.
eNBSourceCodePath
+
'/cmake_targets/'
)
logging
.
debug
(
'
\u001B
[1m Analyzing '
+
nodeB_prefix
+
'NB logfile
\u001B
[0m '
+
file
ToAnalyze
)
logging
.
debug
(
'
\u001B
[1m Analyzing '
+
nodeB_prefix
+
'NB logfile
\u001B
[0m '
+
file
)
logStatus
=
self
.
AnalyzeLogFile_eNB
(
file
ToAnalyze
,
HTML
,
self
.
ran_checkers
)
logStatus
=
self
.
AnalyzeLogFile_eNB
(
file
,
HTML
,
self
.
ran_checkers
)
if
(
logStatus
<
0
):
if
(
logStatus
<
0
):
HTML
.
CreateHtmlTestRow
(
'N/A'
,
'KO'
,
logStatus
)
HTML
.
CreateHtmlTestRow
(
'N/A'
,
'KO'
,
logStatus
)
#display rt stats for gNB only
#display rt stats for gNB only
...
@@ -698,11 +697,16 @@ class RANManagement():
...
@@ -698,11 +697,16 @@ class RANManagement():
datalog_rt_stats
=
yaml
.
load
(
f
,
Loader
=
yaml
.
FullLoader
)
datalog_rt_stats
=
yaml
.
load
(
f
,
Loader
=
yaml
.
FullLoader
)
rt_keys
=
datalog_rt_stats
[
'Ref'
]
#we use the keys from the Ref field
rt_keys
=
datalog_rt_stats
[
'Ref'
]
#we use the keys from the Ref field
if
os
.
path
.
isfile
(
'./nrL1_stats.log'
)
and
os
.
path
.
isfile
(
'./nrMAC_stats.log'
):
# nrL1_stats.log/nrMAC_stats.log should be in the same directory as main log file
# currently the link is only implicit as below based on pattern matching
# I will rework this to give the file explicitly
l1_stats_fn
=
re
.
sub
(
r'enb_[0-9]+'
,
'nrL1_stats'
,
eNBlogFile
)
mac_stats_fn
=
re
.
sub
(
r'enb_[0-9]+'
,
'nrMAC_stats'
,
eNBlogFile
)
if
os
.
path
.
isfile
(
l1_stats_fn
)
and
os
.
path
.
isfile
(
mac_stats_fn
):
# don't use CI-nrL1_stats.log, as this will increase the processing time for
# don't use CI-nrL1_stats.log, as this will increase the processing time for
# no reason, we just need the last occurence
# no reason, we just need the last occurence
nrL1_stats
=
open
(
'./nrL1_stats.log'
,
'r'
)
nrL1_stats
=
open
(
l1_stats_fn
,
'r'
)
nrMAC_stats
=
open
(
'./nrMAC_stats.log'
,
'r'
)
nrMAC_stats
=
open
(
mac_stats_fn
,
'r'
)
for
line
in
nrL1_stats
.
readlines
():
for
line
in
nrL1_stats
.
readlines
():
for
k
in
rt_keys
:
for
k
in
rt_keys
:
result
=
re
.
search
(
k
,
line
)
result
=
re
.
search
(
k
,
line
)
...
@@ -722,7 +726,7 @@ class RANManagement():
...
@@ -722,7 +726,7 @@ class RANManagement():
nrL1_stats
.
close
()
nrL1_stats
.
close
()
nrMAC_stats
.
close
()
nrMAC_stats
.
close
()
else
:
else
:
logging
.
debug
(
"NR Stats files for RT analysis not found
"
)
logging
.
debug
(
f"NR Stats files for RT analysis not found:
{
l1_stats_fn
}
,
{
mac_stats_fn
}
"
)
#stdout log file and stat log files analysis completed
#stdout log file and stat log files analysis completed
logging
.
debug
(
' File analysis (stdout, stats) completed'
)
logging
.
debug
(
' File analysis (stdout, stats) completed'
)
...
...
YanKuo
@yankuo
mentioned in commit
b075c733
·
Dec 17, 2025
mentioned in commit
b075c733
mentioned in commit b075c733f31dbe8c695fbbe1b2d8251206e0d8fd
Toggle commit list
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