Bug 1876853

Summary: pod logs don't show a last line without a newline character (\n) at the end
Product: OpenShift Container Platform Reporter: Filip Krepinsky <fkrepins>
Component: Management ConsoleAssignee: Jon Jackson <jonjacks>
Status: CLOSED ERRATA QA Contact: Siva Reddy <schituku>
Severity: low Docs Contact:
Priority: low    
Version: 4.5CC: aos-bugs, jokerman, spadgett, yapei
Target Milestone: ---   
Target Release: 4.6.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Cause: If the final line of a log was not newline-terminated, it was not displayed in the resource log view. Consequence: Single line logs or logs that ended without newline termination would be missing content in the log view. Fix: Update log view to include the final log line even when it is not newline-terminated. Result: Log view shows entire log content, even when final line is not terminated with a newline.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-10-27 16:38:34 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
pod.yaml
none
Screen shot with pod logs none

Description Filip Krepinsky 2020-09-08 11:16:31 UTC
Created attachment 1714074 [details]
pod.yaml

Description of problem:
pod logs don't show a last line without a newline character (\n) at the end


Steps to Reproduce:
1. Create attached pod.yaml
2. Pod Logs does not show "hello" output


Expected results:
Pod Logs should show the output

Comment 3 Yadan Pei 2020-09-30 05:52:11 UTC
We need newer nightly to test the fix, 4.6.0-0.nightly-2020-09-29-170625 doesn't include the fix yet

Changing QA Contact to Siva then he can verify the bug when there is new build during Chinese holiday

Comment 4 Siva Reddy 2020-10-06 09:16:37 UTC
The pod logs now show the output. Hence moving this bug to verified.

Version:
  4.6.0-0.nightly-2020-10-03-032912

Steps to verify:
1. Create a new project and the create a pod with the pod.yaml attached.
   oc create new-project
   oc create -f pod.yaml
2. Log in to the web console as kube admin
3. Navigate to PageSideBar>Workloads>Pods
4. Select the created project from the drop down
5. Click on the newly created pod in the page displayed.
6. click on the logs tab
7. Note that the "Hello" output is displayed.

attached the screenshot of the page.

Comment 5 Siva Reddy 2020-10-06 09:19:24 UTC
Created attachment 1719311 [details]
Screen shot with pod logs

Comment 8 errata-xmlrpc 2020-10-27 16:38:34 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 (OpenShift Container Platform 4.6 GA Images), 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/RHBA-2020:4196