Bug 662981

Summary: [Multi-Org] ISE when adding virtualization entitlement when org has not VT channel
Product: Red Hat Satellite 5 Reporter: Petr Sklenar <psklenar>
Component: WebUIAssignee: Tomas Lestach <tlestach>
Status: CLOSED ERRATA QA Contact: Šimon Lukašík <slukasik>
Severity: medium Docs Contact:
Priority: medium    
Version: 540CC: slukasik
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Consequence When VT channel wasn't available for an organization and virtualization entitlement was added to a system, the action failed with Internal Server Error Result Nonavailability of VT channel when adding virtualization entitlement isn't fatal.
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-03-17 14:12:40 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 646488    

Description Petr Sklenar 2010-12-14 10:29:21 UTC
Description of problem:
there is ISE when adding virtualization entitlement to machine registered into non-admin org

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

How reproducible:
always

Steps to Reproduce:
1. have a sat540 and sync rhel5 base, tools and vt channels into admin org
2. create non admin organization org-1 and add all available system entitlements , (it means to add virtualization)

3. add channel entitlement only for core server for org-1
4. don't add any other subscription to org-1 - no virtualization channel!

5. register rhel5 machine into org-1
6. add virtualization entitlement to this machine 
  
Actual results:
 error  We're sorry, but the channel could not be found.

This error may have occurred in one of three ways:

   1. The channel requested does not exist. This is most likely if you arrived at this page through bookmarks or some other non-hyperlink.
   2. You do not have permission to view this channel.
   3. You've found an error in our site.



catalina.out:
2010-12-14 05:25:30,794 [TP-Processor8] WARN  com.redhat.rhn.common.errors.LookupExceptionHandler - User 123 does not have access to channel 779 or the channel does not exist



Expected results:
no ise

there is nice error message which inform you about missing channel and adding additional software channel entitlement for org-1


Additional info:
it happens only when rhel-x86_64-server-vt-5 is synced into admin org but nonadmin org-1 is without channel entitlements

Comment 1 Tomas Lestach 2010-12-20 19:03:14 UTC
Fixed.
spacewalk.git: 6c5131ed37eb39085c5a11c688f9620c0789ea97
I also changed warnings to errors, when adding virt entitlement and no tools or VT channel is found.
spacewalk.git: f19676151d0e83a64016a68d3c8a903f74b4af29

Comment 5 Tomas Lestach 2011-02-14 15:13:02 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Consequence
When VT channel wasn't available for an organization and virtualization entitlement was added to a system, the action failed with Internal Server Error

Result
Nonavailability of VT channel when adding virtualization entitlement isn't fatal.

Comment 6 Šimon Lukašík 2011-03-02 10:52:47 UTC
Taking a QA contact.

Comment 7 Šimon Lukašík 2011-03-04 12:20:33 UTC
Moving to Verified.

Testing procedure:
Up to the comment 0 (note to have tools channel entitled in the org1)

Verified against:
spacewalk-java-1.2.39-37

Comment 8 errata-xmlrpc 2011-03-17 14:12:40 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-0362.html