Bug 1186485 - CFME 5.3.2 (Version: 5.3.2.6) does not recognize zone level log depot configuration and so fails to collect logs - different from Bug 1174855
Summary: CFME 5.3.2 (Version: 5.3.2.6) does not recognize zone level log depot configu...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Appliance
Version: 5.3.0
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: GA
: 5.4.0
Assignee: Joe Rafaniello
QA Contact: Jan Krocil
URL:
Whiteboard:
Depends On:
Blocks: 1196358
TreeView+ depends on / blocked
 
Reported: 2015-01-27 18:55 UTC by Thomas Hennessy
Modified: 2015-06-16 12:48 UTC (History)
6 users (show)

Fixed In Version: 5.4.0.0.11
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1196358 (view as bug list)
Environment:
Last Closed: 2015-06-16 12:48:34 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
current logs from appliance where zone level log depot has been configured, zone level log collection requested and initited, but failing (3.11 MB, application/zip)
2015-01-27 18:55 UTC, Thomas Hennessy
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1174855 0 unspecified CLOSED CFME 3.1 Zone level log collection not working as expected 2021-02-22 00:41:40 UTC
Red Hat Product Errata RHBA-2015:1100 0 normal SHIPPED_LIVE CFME 5.4.0 bug fixes, and enhancement update 2015-06-16 16:28:42 UTC

Internal Links: 1174855

Description Thomas Hennessy 2015-01-27 18:55:40 UTC
Created attachment 984837 [details]
current logs from appliance where zone level log depot has been configured, zone level log collection requested and initited, but failing

Description of problem:After instantiating a new VMware appliance with the Version: 5.3.2.6 code base, and then configuring a log depot for the default zone, I attempted to collect logs.  Log collections are initiated but fail with the failure in the evm.log file indicating that the log depot is not configured. (which is incorrect) 


Version-Release number of selected component (if applicable): Version: 5.3.2.6


How reproducible:


Steps to Reproduce:
1. instantiate a new appliance with a configured VMDB.
2. use standard credentials to login to the appliance
3. configure zone level log depot to save to redhat dropbox and save
4. initiate zone level full log collections to dropbox.
5. get UI message indicating log collection is starting
6. wait reasonable time for log collections to occur and search dropbox for log set.

Actual results:  requested logs never appear in the log depot, but the evm.log file shows that CFME has determined that no log depot is configured and so terminates log collection.


Expected results: requested logs to show up in RedHat dropbox.


Additional info:
logs showing error :
=====
[----] E, [2015-01-26T17:56:41.053711 #2139:946830] ERROR -- : MIQ(MiqServer.post_current_logs) Task: [443032000000000113] Posting of current logs failed for CFME-3.2-NONDB default MiqServer 443032000000000002 due to error: [RuntimeError] [Log Depot settings not configured]
[----] E, [2015-01-26T17:56:41.063937 #2139:946830] ERROR -- : MIQ(MiqQueue.deliver)    Message id: [443032000000006705], Error: [Log Depot settings not configured]
[----] E, [2015-01-26T17:56:41.064237 #2139:946830] ERROR -- : [RuntimeError]: Log Depot settings not configured  Method:[rescue in deliver]
[----] E, [2015-01-26T17:56:41.064336 #2139:946830] ERROR -- : /var/www/miq/vmdb/app/models/log_file.rb:53:in `upload'
=====
full current logs from failing appliance are attached including prodution log from which one can see that the zone level configuration has been completed before the log collection is requested.

Also, individual appliance level log depot settings were later created and appliance level log collections initiated to dropbox and these were successful.

Comment 2 Joe Rafaniello 2015-02-18 16:27:40 UTC
This looks like fallout from this commit:

https://github.com/ManageIQ/manageiq/commit/a42bb4f829e34781d433854c7aca0db5ec36982f

Comment 3 Joe Rafaniello 2015-02-23 23:02:38 UTC
Upstream PR https://github.com/ManageIQ/manageiq/pull/1850

Comment 4 CFME Bot 2015-02-25 17:10:54 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/146dd50246dfd70b44e46e5e51a741a7508e803b

commit 146dd50246dfd70b44e46e5e51a741a7508e803b
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Mon Feb 23 17:53:11 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Mon Feb 23 17:59:31 2015 -0500

    Use log_depot for MiqServer#log_file_depot or Zone#log_file_depot
    
    When the Zone level log_file_depot is configured, but not the MiqServer, MiqServer#log_file_depot is nil, so we need to look for the Zone's depot.
    
    Commit 4f0c1b542649bb8b4c99d8f584582aeef439cefa, changed log collection to use relationships to get the file depots but only on the server.
    It missed that we can configure the depot at the server or zone or both and that we should look for the server's first, then the zone's.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/app/models/miq_server/log_management.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comment 5 CFME Bot 2015-02-25 17:11:01 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/9ff74a7feee8c29e12c44d8df108095545c8b88b

commit 9ff74a7feee8c29e12c44d8df108095545c8b88b
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Tue Feb 24 16:25:19 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Tue Feb 24 16:38:44 2015 -0500

    Add some tests for MiqServer#log_depot
    
    Change factory to specify a URI by default.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/spec/factories/file_depot.rb                  |  1 +
 vmdb/spec/models/miq_server/log_management_spec.rb | 25 ++++++++++++++++++++++
 2 files changed, 26 insertions(+)

Comment 6 CFME Bot 2015-02-25 17:11:04 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/52da34cfd7893bfe9f7b3da4eeafce6397ef3939

commit 52da34cfd7893bfe9f7b3da4eeafce6397ef3939
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Tue Feb 24 16:33:37 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Tue Feb 24 16:38:47 2015 -0500

    Define the uri "let" before it's referenced.
    
    It was correct before, but this makes it easier to read.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/spec/models/miq_server/log_management_spec.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 7 CFME Bot 2015-02-25 17:11:07 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/c316aeb753d028486efe0bbdc720897be26c4b69

commit c316aeb753d028486efe0bbdc720897be26c4b69
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Tue Feb 24 16:32:03 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Tue Feb 24 16:38:47 2015 -0500

    Existing uses of the file_depot factory should use the default uri.
    
    They don't need something different so use the default.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/spec/models/log_collection_spec.rb            | 2 +-
 vmdb/spec/models/miq_server/log_management_spec.rb | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Comment 8 Joe Rafaniello 2015-02-25 19:37:39 UTC
Note, this only fails if the Zone is configured and the MiqServer(appliance) is NOT configured with a log depot.

Comment 9 CFME Bot 2015-02-25 19:51:01 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=05bddadec3971cf3bc129e986f7e3f815526e1cd

commit 05bddadec3971cf3bc129e986f7e3f815526e1cd
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Mon Feb 23 17:53:11 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Wed Feb 25 14:44:24 2015 -0500

    Use log_depot for MiqServer#log_file_depot or Zone#log_file_depot
    
    When the Zone level log_file_depot is configured, but not the MiqServer, MiqServer#log_file_depot is nil, so we need to look for the Zone's depot.
    
    Commit 4f0c1b542649bb8b4c99d8f584582aeef439cefa, changed log collection to use relationships to get the file depots but only on the server.
    It missed that we can configure the depot at the server or zone or both and that we should look for the server's first, then the zone's.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/app/models/miq_server/log_management.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comment 10 CFME Bot 2015-02-25 19:51:05 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=51a5e203727e2fd7cb691e442e5984ee03b07853

commit 51a5e203727e2fd7cb691e442e5984ee03b07853
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Tue Feb 24 16:25:19 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Wed Feb 25 14:44:27 2015 -0500

    Add some tests for MiqServer#log_depot
    
    Change factory to specify a URI by default.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/spec/factories/file_depot.rb                  |  1 +
 vmdb/spec/models/miq_server/log_management_spec.rb | 25 ++++++++++++++++++++++
 2 files changed, 26 insertions(+)

Comment 11 CFME Bot 2015-02-25 19:51:09 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=9e348bcb48c2e09446225c6f42673680e27d0720

commit 9e348bcb48c2e09446225c6f42673680e27d0720
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Tue Feb 24 16:32:03 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Wed Feb 25 14:44:31 2015 -0500

    Existing uses of the file_depot factory should use the default uri.
    
    They don't need something different so use the default.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/spec/models/log_collection_spec.rb            | 2 +-
 vmdb/spec/models/miq_server/log_management_spec.rb | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Comment 12 CFME Bot 2015-02-25 19:51:11 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=5fed3896daaa403c2eef42258be2b5aae058843c

commit 5fed3896daaa403c2eef42258be2b5aae058843c
Author:     Joe Rafaniello <jrafanie>
AuthorDate: Tue Feb 24 16:33:37 2015 -0500
Commit:     Joe Rafaniello <jrafanie>
CommitDate: Wed Feb 25 14:44:34 2015 -0500

    Define the uri "let" before it's referenced.
    
    It was correct before, but this makes it easier to read.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1186485

 vmdb/spec/models/miq_server/log_management_spec.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 14 Jan Krocil 2015-06-05 12:56:04 UTC
Verified fixed in 5.4.0.4 (5.4.0.4.20150528174021_88cc76c).

Zone level log collection now works correctly.

Comment 16 errata-xmlrpc 2015-06-16 12:48: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, 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://rhn.redhat.com/errata/RHBA-2015-1100.html


Note You need to log in before you can comment on or make changes to this bug.