RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1039755 - Port Openshift sosreport Plugin into Openshift
Summary: Port Openshift sosreport Plugin into Openshift
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: sos
Version: 6.6
Hardware: All
OS: All
urgent
urgent
Target Milestone: rc
: 6.6
Assignee: Bryn M. Reeves
QA Contact: Miroslav Hradílek
URL:
Whiteboard:
Depends On:
Blocks: 994246
TreeView+ depends on / blocked
 
Reported: 2013-12-09 22:18 UTC by Nick Harvey
Modified: 2017-02-07 12:24 UTC (History)
10 users (show)

Fixed In Version: sos-2.2-61.el6
Doc Type: Enhancement
Doc Text:
Feature: Diagnostic data from OpenShift installations is now captured and stored in the report tarball. Reason: Previous versions of sos did not capture diagnostic data for OpenShift Node and Broker installations. Result: Configuration and state information is now collected on applicable systems.
Clone Of:
Environment:
Last Closed: 2014-10-14 07:22:44 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
2.0 version patch (2.76 KB, text/plain)
2014-01-06 21:29 UTC, Eric Rich
no flags Details
patch openshift.py to reduce glob based collection, obfuscate pwd (1.70 KB, patch)
2014-07-07 13:18 UTC, Josep 'Pep' Turro Mauri
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2014:1528 0 normal SHIPPED_LIVE sos bug fix and enhancement update 2014-10-14 01:22:00 UTC

Description Nick Harvey 2013-12-09 22:18:32 UTC
Description of problem: the upstream version of sosreport has a plugin for Openshift and we need to bring it into RHEL

https://github.com/sosreport/sosreport/blob/master/sos/plugins/openshift.py


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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Eric Rich 2013-12-09 22:20:55 UTC
Would it be possible to get this backported into 6.5?

Comment 3 Eric Rich 2014-01-06 21:29:00 UTC
Created attachment 846313 [details]
2.0 version patch

I have created https://github.com/sosreport/sosreport/pull/228 to apply this patch to the community version of the code.

Comment 12 Luke Meyer 2014-03-25 18:49:50 UTC
Might it make more sense to ship a sosreport plugin in OpenShift Enterprise instead?

We can ship fixes a lot faster than RHEL, and more than one version of OSE is supported on RHEL at a time.

Comment 13 Eric Rich 2014-03-25 19:50:49 UTC
(In reply to Luke Meyer from comment #12)
> Might it make more sense to ship a sosreport plugin in OpenShift Enterprise
> instead?
> 
> We can ship fixes a lot faster than RHEL, and more than one version of OSE
> is supported on RHEL at a time.

Are we also going to ship/maintain the mongo sosreport plugin and the AMQ plugin that the ose plugin will be using (at lease that is the desing Bryn and I discussed)? 

I think it makes since for us to ship / support the OSE and Mongo plugins out of OSE but AMQ should come from the AMQ channels or RHEL depending on who wants to ship / support them. 

When this starts to happen I think we start getting into some interesting dependency issues with entitlements (potentaly). 

- I point out this would only be a real problem if we ever swith message brokers or the DB that we support, or if we ever start support multiples (etc, etc)

Comment 15 Bryn M. Reeves 2014-06-30 11:45:12 UTC
> I think it makes since for us to ship / support the OSE and Mongo plugins out 
> of OSE but AMQ should come from the AMQ channels or RHEL depending on who 
> wants to ship / support them. 

Experience shows that this tends to get complicated quite quickly; it's almost always easier to just include everything in the main sos RPM. Unless there are differences of schedule that cannot be reconciled this is the preferred approach (and in that case it's generally better to ship a modified sos package in the other product's channels rather than fragmenting it across several packages/channels).

> For things like Mongo OSE and the SCL behave differently, is this being 
> considered when thinking about the sosplugin for mongo

Can you elaborate on the requirements here?

If it's not been recorded in bugzilla or the upstream issue-tracker it probably has not been taken into consideration.

Comment 16 Eric Rich 2014-06-30 13:42:07 UTC
(In reply to Bryn M. Reeves from comment #15)
channels).
> > For things like Mongo OSE and the SCL behave differently, is this being 
> > considered when thinking about the sosplugin for mongo
> 
> Can you elaborate on the requirements here?
> 
> If it's not been recorded in bugzilla or the upstream issue-tracker it
> probably has not been taken into consideration.

OpenShift Ships a version of Mongo that is it uses for the Broker (application). However we use the Mongo from the SCL to provide a cartridge for developers / users of the system. 

If were developing a Mongo sos-plugin that is RHEL supported I would assume that we would be looking for data from the SCL. As RHEL only supports Mongo out of this location. 

However the rub here is that OpenShift uses mongo stored out of a standard RPM install of mongo (IE: /etc, /var/log, etc) but this RPM is only shipped with add on products like OpenShift or OpenStack and between products they may not be the same version or distribution. 

Just wanted to know if this was considered when looking at the (dependency plugins).

Comment 17 Luke Meyer 2014-06-30 13:50:33 UTC
To make it more interesting, now that the MongoDB SCL has actually been released, it would not surprise me if OpenShift and/or OpenStack start relying on that in the near future instead of shipping MongoDB separately.

Comment 18 Bryn M. Reeves 2014-07-04 13:50:36 UTC
I think these concerns belong upstream really; we won't make changes speculatively in RHEL6 for things that could happen in the future (e.g. OpenShift using an SCL version of Mongo). Once the change is being actively planned for a release we can revisit the sos support and adapt as needed.

I'm planning to take the OpenShift plugin (and related modules) that are now upstream and backport those pretty much 1:1 to sos-2.2.

Comment 19 Bryn M. Reeves 2014-07-04 16:47:51 UTC
commit f58eb6e445962a74c15e27cd010a890873a0046a
Author: Bryn M. Reeves <bmr>
Date:   Fri Jul 4 18:39:01 2014 +0100

    [mongodb] backport new plugin from upstream

commit 3774c418b967878081799b0c500cda4bf94a7049
Author: Bryn M. Reeves <bmr>
Date:   Fri Jul 4 18:38:45 2014 +0100

    [activemq] backport new plugin from upstream

commit 2264655266ff81e5bba3c016f247da34cc3edb04
Author: Bryn M. Reeves <bmr>
Date:   Fri Jul 4 18:38:22 2014 +0100

    [openshift] sync plugin with upstream

commit 1672d26505b76fc708f015377343c1e1ee2fffb4
Author: Bryn M. Reeves <bmr>
Date:   Fri Jul 4 18:36:49 2014 +0100

    [plugin] backport collectExtOutputs and addCopySpecs
    
    Backport the plural collection methods from upstream. This
    simplifies plugin backports (simple search-and-replace rather
    than converting a list argument into multiple function calls).

commit 27cf8454651453553a60c20c38040dbc3ccb770e
Author: Bryn M. Reeves <bmr>
Date:   Thu Dec 20 16:59:28 2012 +0000

    Make OpenShift module collect domain information
    
    Make the OpenShift module attempt a zone transfer for its domain
    (rather than it's hostname as originally implemented).

commit f4d351fb9d08667995254d2431a39e7d136e404c
Author: Bryn M. Reeves <bmr>
Date:   Mon Dec 17 19:55:24 2012 +0000

    Add 'gear' option to OpenShift module
    
    Add an option to allow the user to specify an optional gear UUID.

commit 51960a6af2fff7eb0914ddeccd859ae1bcd6a2c5
Author: Bryn M. Reeves <bmr>
Date:   Mon Dec 17 19:07:38 2012 +0000

    Add OpenShift module
    
    Add a module to collect OpenShift broker and node information.

Comment 20 Josep 'Pep' Turro Mauri 2014-07-07 13:18:07 UTC
Created attachment 916078 [details]
patch openshift.py to reduce glob based collection, obfuscate pwd

The /etc/openshift glob is collecting key material, replaced it with more targeted collection.

Also we were missing some obfuscation in the node's mcollective configuration.

Comment 21 Bryn M. Reeves 2014-07-07 13:26:47 UTC
> -            "/etc/openshift-enterprise-*",
> +            "/etc/openshift-enterprise-release",
 
Is this intentional? Iirc upstream the glob was required to match two possible variants in this path name?

>                  "/cgroup/*/openshift",

I missed this upstream; it's not a big deal for now but we should rip this out in future - it's duplicating paths collected by the cgroups plugin (and /cgroup isn't going to exist on anything up to date anyway).

Comment 22 Josep 'Pep' Turro Mauri 2014-07-07 13:52:46 UTC
(In reply to Bryn M. Reeves from comment #21)
> > -            "/etc/openshift-enterprise-*",
> > +            "/etc/openshift-enterprise-release",
>  
> Is this intentional? Iirc upstream the glob was required to match two
> possible variants in this path name?

In the upstream discussion there was a doubt about the file name; I've checked and at least for OSE 2.x it's -release, and as the plugin is aiming at 2.x and the patch was reducing glob-based collection I thought I'd update that too, feel free to ignore here and we'll clean up upstream for future versions.

> >                  "/cgroup/*/openshift",
> 
> I missed this upstream; it's not a big deal for now but we should rip this
> out in future - it's duplicating paths collected by the cgroups plugin (and
> /cgroup isn't going to exist on anything up to date anyway).

Yup we noticed during testing too... there are other minor things in the plugins that should be improved, but the patch in comment #20 was only aiming at the more serious parts (involving password/key collection).

Comment 28 Eric Rich 2014-08-22 18:28:44 UTC
https://github.com/openshift/origin-server/pull/5743 << This is something being considered (for node debuging) it would be nice to check for the ARCHIVE_DESTROYED_GEARS variable and ARCHIVE_DESTROYED_GEARS_DIR on a node and include that with what the node collects.

Comment 31 errata-xmlrpc 2014-10-14 07:22:44 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.

http://rhn.redhat.com/errata/RHBA-2014-1528.html


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