Commit 5cadafc1 authored by Robert Schmidt's avatar Robert Schmidt

CI: check for final 'Bye.' message

parent 6f40b619
...@@ -46,6 +46,7 @@ ENB_PROCESS_NOLOGFILE_TO_ANALYZE = -14 ...@@ -46,6 +46,7 @@ ENB_PROCESS_NOLOGFILE_TO_ANALYZE = -14
ENB_PROCESS_SLAVE_RRU_NOT_SYNCED = -15 ENB_PROCESS_SLAVE_RRU_NOT_SYNCED = -15
ENB_REAL_TIME_PROCESSING_ISSUE = -16 ENB_REAL_TIME_PROCESSING_ISSUE = -16
ENB_RETX_ISSUE = -17 ENB_RETX_ISSUE = -17
ENB_SHUTDOWN_NO_BYE = -18
HSS_PROCESS_FAILED = -2 HSS_PROCESS_FAILED = -2
HSS_PROCESS_OK = +2 HSS_PROCESS_OK = +2
MME_PROCESS_FAILED = -3 MME_PROCESS_FAILED = -3
......
...@@ -812,6 +812,7 @@ class RANManagement(): ...@@ -812,6 +812,7 @@ class RANManagement():
ULRetxIssue = False ULRetxIssue = False
nrRrcRcfgComplete = 0 nrRrcRcfgComplete = 0
harqFeedbackPast = 0 harqFeedbackPast = 0
showedByeMsg = False # last line is Bye. -> stopped properly
line_cnt=0 #log file line counter line_cnt=0 #log file line counter
for line in enb_log_file.readlines(): for line in enb_log_file.readlines():
...@@ -1024,6 +1025,12 @@ class RANManagement(): ...@@ -1024,6 +1025,12 @@ class RANManagement():
if result is not None: if result is not None:
gnb_markers[k].append(line_cnt) gnb_markers[k].append(line_cnt)
# check whether e/gNB log finishes with "Bye." message
# Note that it is "=" not "|=" so not only is the regex
# asking for EOF (\Z) but we also only retain the last
# line's result
showedByeMsg = re.search(r'^Bye.\n\Z', str(line), re.MULTILINE) is not None
enb_log_file.close() enb_log_file.close()
...@@ -1208,6 +1215,13 @@ class RANManagement(): ...@@ -1208,6 +1215,13 @@ class RANManagement():
logging.debug('No real time stats found in the log file') logging.debug('No real time stats found in the log file')
htmleNBFailureMsg += statMsg htmleNBFailureMsg += statMsg
if not showedByeMsg:
logging.debug('\u001B[1;37;41m ' + nodeB_prefix + 'NB did not show "Bye." message at end, it likely did not stop properly! \u001B[0m')
htmleNBFailureMsg += 'No Bye. message found, did not stop properly\n'
global_status = CONST.ENB_SHUTDOWN_NO_BYE
else:
logging.debug('"Bye." message found at end.')
else: else:
#Removing UE log #Removing UE log
statMsg = '[MAC] Removing UE msg count = '+str(removing_ue) statMsg = '[MAC] Removing UE msg count = '+str(removing_ue)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment