Bug 607379

Summary: org.migrateSystems API call fails on Xen hosts
Product: Red Hat Satellite 5 Reporter: Colin Coe <colin.coe>
Component: APIAssignee: Milan Zázrivec <mzazrivec>
Status: CLOSED ERRATA QA Contact: Pavel Novotny <pnovotny>
Severity: medium Docs Contact:
Priority: low    
Version: 530CC: cperry, pnovotny, tao, tlestach
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Cause: a bug in the code. Consequence: migrating virtualization host system between organizations would fail in situations where both the host and its guests were registered with RHN Satellite. Fix: get rid of the bug in the code. Result: migration of virt. host between organizations in the problematic scenario now works all right.
Story Points: ---
Clone Of:
: 667432 (view as bug list) Environment:
Last Closed: 2011-03-17 14:12:45 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: 667432    
Bug Blocks: 646488    
Attachments:
Description Flags
catalina.out none

Description Colin Coe 2010-06-24 00:20:14 UTC
Description of problem:
org.migrateSystems API call fails on Xen hosts

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

How reproducible:
Any use of org.migrateSystems using a Xen host's system ID results in an internal systems error.

Steps to Reproduce:
#!/usr/bin/perl
use Frontier::Client;
$client = new Frontier::Client(url    => "http://$HOST/rpc/api");
$session = $client->call('auth.login', $user, $pass);
@list = ( 1000011023 );
$client->call('org.migrateSystems', $session, 122, \@list);
$client->call('auth.logout', $session);
  
Actual results:
500 Internal Server Error

Expected results:
No error.  System 1000011023 should have been migrated from org 1 to org 122.

Additional info:
Extract from /var/log/tomcat5/catalina.out is attached.

Comment 1 Colin Coe 2010-06-24 00:21:16 UTC
Created attachment 426420 [details]
catalina.out

Comment 3 Milan Zázrivec 2011-01-05 15:38:25 UTC
Bug cloned for Spacewalk: https://bugzilla.redhat.com/show_bug.cgi?id=667432

Comment 7 Milan Zázrivec 2011-02-15 09:32:56 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:
Cause: a bug in the code.

Consequence: migrating virtualization host system between organizations would fail in situations where both the host and its guests were registered with RHN Satellite.

Fix: get rid of the bug in the code.

Result: migration of virt. host between organizations in the problematic scenario now works all right.

Comment 8 Pavel Novotny 2011-03-07 15:16:02 UTC
VERIFIED.

Reproducer:
1) Prerequisite: You must have two organizations in your Satellite which trust
to each other.
2) Register a Xen-host machine into organization#1 with
Virtualization/Virtualization Platform entitlement.
3) Create a new virtual system on it (Xen-host machine -> Virtualization ->
Provisioning)
4) After guest system is being created, try to migrate the Xen-host system from
organization#1 to organization#2 using the API script portion mentioned in
#Description.

Results:
Old packages (spacewalk-java-1.2.39-35.1.el5sat):
500 Internal Server Error

New packages (spacewalk-java-1.2.39-37.el5sat):
System is successfully migrated.

Comment 9 errata-xmlrpc 2011-03-17 14:12:45 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