Bug 1023374

Summary: oo-admin-check-source tool only check one version if there are two versions on a server.
Product: OpenShift Container Platform Reporter: Ma xiaoqiang <xiama>
Component: NodeAssignee: John W. Lamb <jolamb>
Status: CLOSED ERRATA QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 2.0.0CC: bleanhar, libra-onpremise-devel, xtian
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-12-16 09:11:00 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:

Description Ma xiaoqiang 2013-10-25 09:53:59 UTC
Description of problem:
When I register the channels of version 1.2 and version 2.0; the tool only checks resource with one version.

Version-Release number of selected component (if applicable):
https://github.com/openshift/openshift-extras/tree/enterprise-2.0/admin/check-sources

How reproducible:
always

Steps to Reproduce:
1.register rhn channel 
#rhnreg_ks --username=user --password=passwd --serverUrl=https://xmlrpc.rhn.errata.stage.redhat.com/XMLRPC
#rhn-channel -a -c rhel-x86_64-server-6-ose-1.2-infrastructure -u user -p passwd 
#rhn-channel -a -c rhel-x86_64-server-6-ose-2.0-infrastructure -u user -p passwd 
2.run command  to check resource 
./oo-admin-check-sources.py  -r node  
       
Actual results:
Output:
If this system will be providing the JBossEAP cartridge, re-run this command with the --role=node-eap argument
Detected installed OpenShift Enterprise version 1.2
Checking if yum-plugin-priorities is installed
The required OpenShift Enterprise repositories are missing: ['jb-ews-2-x86_64-server-6-rpm', 'rhel-x86_64-server-6-ose-1.2-node']
Add the missing repositories with the following commands:
# rhn-channel -a -c jb-ews-2-x86_64-server-6-rpm
# rhn-channel -a -c rhel-x86_64-server-6-ose-1.2-node
Checking channel/repository priorities
Please re-run this tool after making any recommended repairs to this system
there are two versions on the server ,  the tool check the resource with version 1.2

Expected results:
The tool should show version conflict, then exit.

Additional info:

Comment 2 John W. Lamb 2013-10-30 21:41:41 UTC
Addressed in https://github.com/openshift/openshift-extras/pull/127

Comment 3 Ma xiaoqiang 2013-10-31 05:04:39 UTC
check it on the new version
priority:
ose-2.0:rhsm -> ose-2.0:rhn -> ose-1.2:rhsm -> ose-2.0:rhn

Comment 4 Ma xiaoqiang 2013-10-31 06:18:30 UTC
(In reply to Ma xiaoqiang from comment #3)
> check it on the new version
> priority:
> ose-2.0:rhsm -> ose-2.0:rhn -> ose-1.2:rhsm -> ose-2.0:rhn


the priority should be:
ose-2.0:rhsm -> ose-2.0:rhn -> ose-1.2:rhsm -> ose-1.2:rhn