Fix find_msg_in_file method to search in active log file only
In the new environment logs are not yet rotated so there is no log.1 file available. Change-Id: Ic8f2e6a372c0ab5989fc2ca3d3beb4478e93063d
This commit is contained in:
parent
2a5113853c
commit
eb6c511ed0
|
@ -238,7 +238,7 @@ def find_msg_in_file(node, logfile, message, rotated=False):
|
|||
if rotated:
|
||||
suffix = ".1"
|
||||
else:
|
||||
suffix = "{,.1}"
|
||||
suffix = ""
|
||||
LOG.debug(f'Searching for {message} in {logfile}{suffix} on {node.name}')
|
||||
result = sh.execute(f'sudo grep -h {message} {logfile}{suffix}',
|
||||
ssh_client=node.ssh_client,
|
||||
|
|
Loading…
Reference in New Issue