Bug 1768873

Summary: Fix rhv-log-collector-analyzer tool or doc
Product: Red Hat Enterprise Virtualization Manager Reporter: Marko Myllynen <myllynen>
Component: rhv-log-collector-analyzerAssignee: Douglas Schilling Landgraf <dougsland>
Status: CLOSED ERRATA QA Contact: Guilherme Santos <gdeolive>
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: lleistne, lsvaty, mtessun, Rhev-m-bugs
Target Milestone: ovirt-4.3.7Keywords: FieldEngineering, Regression
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rhv-log-collector-analyzer-0.2.13-0.el7ev Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-12-12 10:36:35 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Integration RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Marko Myllynen 2019-11-05 12:49:21 UTC
Description of problem:
On RHV 4.3.6.2 rhv-log-collector-analyzer does not accept the documented --html command line option (errors out with "Invalid option '--html=/tmp/test.html'"):

https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.3/html/upgrade_guide/analyzing_the_environment_4-2_local_db_ff

This used to work earlier, around 4.3.5 or so.

Please either restore the old functionality or adjust the documentation to match the implementation. Since the old version was slightly more flexible, perhaps restoring the old functionality would be somewhat preferred. Thanks.

Version-Release number of selected component (if applicable):
RHV 4.3.6.2
rhv-log-collector-analyzer-0.2.9-0.el7ev.noarch

Comment 1 Sandro Bonazzola 2019-11-05 13:47:59 UTC
--html has been removed by mistake, we are re-introducing it.

Comment 3 Douglas Schilling Landgraf 2019-11-06 17:20:33 UTC
commit 2cd280c24c7281cafbb03d452b0d616d89d98c9b
Author: Douglas Schilling Landgraf <dougsland>
Date:   Tue Nov 5 15:13:21 2019 -0500

    analyzer: Add back --html
    
    Previously, --html option was removed. This patch adds back.

diff --git a/src/rhv-log-collector-analyzer.sh b/src/rhv-log-collector-analyzer.sh
index 5db3def..55f64e1 100755
--- a/src/rhv-log-collector-analyzer.sh
+++ b/src/rhv-log-collector-analyzer.sh
@@ -24,6 +24,10 @@ Usage: $0 [options]
         Use live system to determine possible issues, output HTML
     --json
         Use live system to determine possible issues, output JSON
+    -html=<file>
+        Write html report to <file>. Defaults to ${HTML_OUT} .
+    --version
+        Report application version and exit
 __EOF__
 exit 1;
 
@@ -59,6 +63,9 @@ while [ -n "$1" ]; do
             --version)
                 version
                 ;;
+           --html=*)
+                HTML_OUT="${v}"
+                ;;
             *)
                 echo "Invalid option '${x}'"
                 exit 1

Comment 5 Guilherme Santos 2019-11-08 10:07:30 UTC
Verified on:
rhv-log-collector-analyzer-0.2.13-0.el7ev.noarch

Steps:
# rhv-log-collector-analyzer --help
# rhv-log-collector-analyzer --html=test_file.html

Results:
--html present on help and test_file.html created with success

Comment 7 errata-xmlrpc 2019-12-12 10:36:35 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, 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-2019:4229