Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 766895 - Addition of hypervisorCheckIn call
Addition of hypervisorCheckIn call
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: subscription-manager (Show other bugs)
5.8
Unspecified Unspecified
unspecified Severity unspecified
: rc
: 5.8
Assigned To: William Poteat
Entitlement Bugs
:
Depends On:
Blocks: 769266
  Show dependency treegraph
 
Reported: 2011-12-12 14:01 EST by William Poteat
Modified: 2012-08-10 09:06 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Addition of hypervisorCheckIn call to allow sending a mapping of host/guest ids for creation/update.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-02-21 01:43:56 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0154 normal SHIPPED_LIVE subscription-manager bug fix update 2012-02-20 10:06:04 EST

  None (edit)
Description William Poteat 2011-12-12 14:01:09 EST
Incorporation of feature:

Addition of hypervisorCheckIn call to allow sending a mapping of host/guest ids for creation/update.
Comment 3 John Sefler 2012-01-17 18:12:29 EST
Demonstrating... When virt-who is run, it can successfully send an update to the candlepin server so that the consumer on the host becomes aware of the guests being run on the host.  This feature allows candlepin.standalone=true to be aware of guests being run on a host and therefore provide a realistic "RHEL subscription with up-to N virtual guests" model.



Verifying Version...
[root@margo ~]# rpm -q subscription-manager
subscription-manager-0.98.11-1.el5
[root@margo ~]# rpm -q virt-who
virt-who-0.5-3.el5
[root@margo ~]# curl -k --user admin:admin https://mgmt5.rhq.lab.eng.bos.redhat.com:8443/candlepin/status
{"version":"0.5.10","result":true,"standalone":true,"release":"1"}



On a RHEL58 Server host running xen virtualization...
[root@margo ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 5.8 Beta (Tikanga)
[root@margo ~]# xen-detect
Running in PV context on Xen v3.1.
[root@margo ~]# virsh list
 Id Name                 State
----------------------------------
  0 Domain-0             running
  2 stacking-guest       idle
[root@margo ~]# virt-what
xen
xen-dom0
[root@margo ~]# subscription-manager facts --list | grep is_guest
virt.is_guest: False

[root@margo ~]# subscription-manager register --username testuser1 --password password --org admin
The system has been registered with id: 362f9bc7-58d6-4c3c-9bdf-e29734037b6f 

^^^ THE HOST IS NOW REGISTERED AND WE HAVE A CONSUMER ID FOR THE HOST



Demonstrating virt-who's ability to upload the virt.uuids of the guests running on the host to candlepin...
[root@margo ~]# virt-who -d
Virt-who is running in libvirt mode
Virtual machine found: stacking-guest: fd0c533a-a5c9-c83e-9265-22a9215327e2
Sending update to updateConsumer: ['fd0c533a-a5c9-c83e-9265-22a9215327e2']




On a RHEL58 Server guest of the host...
[root@localhost ~]# virt-what
xen
xen-domU
[root@localhost ~]# subscription-manager facts --list | grep is_guest
virt.is_guest: True
[root@localhost ~]# 
[root@localhost ~]# subscription-manager register --username testuser1 --password password --org admin
The system has been registered with id: 6e1e5830-8237-4a06-a02b-39681dec96c9 
[root@localhost ~]# 
[root@localhost ~]# subscription-manager facts --list | grep uuid
system.uuid: 6e1e5830-8237-4a06-a02b-39681dec96c9
virt.uuid: fd0c533a-a5c9-c83e-9265-22a9215327e2

^^^ THE GUEST IS NOW REGISTERED AND WE HAVE A CONSUMER ID AND ITS virt.uuid MATCHES WHAT virt-who SENT TO CANDLEPIN



NOW LET'S CALL THE /guests API ON THE HOST CONSUMER AND WE SHOULD FIND THE GUEST...
[root@margo ~]# curl -k --user admin:admin https://mgmt5.rhq.lab.eng.bos.redhat.com:8443/candlepin/consumers/362f9bc7-58d6-4c3c-9bdf-e29734037b6f/guests | python -m simplejson/tool | grep uuid
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5618    0  5618    0     0  39625      0 --:--:-- --:--:-- --:--:--     0
            "virt.uuid": "fd0c533a-a5c9-c83e-9265-22a9215327e2"
        "uuid": "6e1e5830-8237-4a06-a02b-39681dec96c9"
[root@margo ~]# 

^^^^ THANKS TO virt-who's COMMUNICATION TO CANDLEPIN, WE HAVE VERIFIED THAT THE HOST CONSUMER IS AWARE OF THE REGISTERED GUEST SYSTEM'S uuid THROUGH ITS virt.uuid.



Moving to VERIFIED
Comment 4 William Poteat 2012-01-23 11:29:27 EST
    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:
Addition of hypervisorCheckIn call to allow sending a mapping of host/guest ids for creation/update.
Comment 5 errata-xmlrpc 2012-02-21 01:43:56 EST
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-2012-0154.html

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