Bug 1947828

Summary: `download it` link should save pod log in <pod-name>-<container-name>.log format
Product: OpenShift Container Platform Reporter: Yadan Pei <yapei>
Component: Management ConsoleAssignee: Jakub Hadvig <jhadvig>
Status: CLOSED ERRATA QA Contact: Xiyun Zhao <xiyuzhao>
Severity: low Docs Contact:
Priority: unspecified    
Version: 4.8CC: aos-bugs, jokerman, spadgett, yapei
Target Milestone: ---   
Target Release: 4.8.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 4.8.0-0.nightly-2021-04-15-152737 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-07-27 22:58:29 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
download it link appears when there are long lines in log none

Description Yadan Pei 2021-04-09 10:47:33 UTC
Description of problem:
when viewing long pod logs, we will show a warning message and provides a link to download the log file, currently the pod log file will be saved as `log.txt` it is not easy to differentiate when we download multiple pod logs  

Version-Release number of selected component (if applicable):
4.8.0-0.nightly-2021-04-08-124424

How reproducible:
Always

Steps to Reproduce:
1. view some long pod logs, such as console operator logs, click the `download it` in hint message


Actual results:
1. when logs are long, we will show a hint message `Warning alert:Some lines have been abridged because they are exceptionally long.
To view unabridged log content, you can either open the raw file in another window or download it.`
clicking on `download it` will save the pod log file as `log.txt`

Expected results:
1. it's better to save the pod log file in `${pod-name}-${container_name}.log`

Additional info:

Comment 1 Yadan Pei 2021-04-09 11:18:19 UTC
Created attachment 1770550 [details]
download it link appears when there are long lines in log

Comment 4 Xiyun Zhao 2021-04-16 07:58:44 UTC
This bug has been verified and fixed on payload 4.8.0-0.nightly-2021-04-15-152737

Verify Steps:
View some long pod logs, such as console operator, cluster-node-tuning-operator and so on, click the `download it` in hint message

Result: 1. User is able to download and save the pod log file successfully
        2. The name of log file is update to the format of `${pod-name}-${container_name}.log`

Additional Info:
Although the testing pod has long pod logs, but in this verification testing, no waring message has been triggered.

Comment 5 Xiyun Zhao 2021-04-16 08:42:49 UTC
This bug has been verified and fixed on payload 4.8.0-0.nightly-2021-04-15-152737

Verify Steps:
View some long pod logs, such as console operator, cluster-node-tuning-operator, webhook and so on, click the `download it` in hint message

Result: 1. User is able to download and save the pod log file successfully
        2. The name of log file is update to the format of `${pod-name}-${container_name}.log`

Comment 6 Xiyun Zhao 2021-04-16 08:43:33 UTC
This bug has been verified and fixed on payload 4.8.0-0.nightly-2021-04-15-152737

Verify Steps:
View some long pod logs, such as console operator, cluster-node-tuning-operator, webhook and so on, click the `download it` in hint message

Result: 1. User is able to download and save the pod log file successfully
        2. The name of log file is update to the format of `${pod-name}-${container_name}.log`

Comment 9 errata-xmlrpc 2021-07-27 22:58:29 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.8.2 bug fix and security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:2438