Bug 1041165

Summary: [RFE][nova]: Expose host UUID from libvirt through the API
Product: Red Hat OpenStack Reporter: RHOS Integration <rhos-integ>
Component: RFEsAssignee: RHOS Maint <rhos-maint>
Status: CLOSED DEFERRED QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: markmc, sgordon, yeylon
Target Milestone: ---Keywords: FutureFeature
Target Release: 5.0 (RHEL 7)   
Hardware: Unspecified   
OS: Unspecified   
URL: https://blueprints.launchpad.net/nova/+spec/libvirt-host-uuid
Whiteboard: upstream_milestone_none upstream_status_deferred upstream_definition_superseded
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-23 21:11:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description RHOS Integration 2013-12-12 13:49:56 UTC
Cloned from launchpad blueprint https://blueprints.launchpad.net/nova/+spec/libvirt-host-uuid.

Description:

This blueprint is for adding an additional 'hypervisor_uuid' detail to the hypervisor details list.

The hypervisor's UUID is useful to the ceilometer katello dispatcher plugin (https://github.com/Katello/ceilometer_katello_dispatcher), which needs UUIDs of both hypervisors and instances in order to populate katello with a map of which instances are running on which hypervisors. Katello and its backend entitlement service candlepin use UUIDs to track system information.

Additionally, the hypervisor UUID is a handy identifier for verifying which hypervisor is being referred to in the nova cli output.

I'd like to make the following changes:

 * add a hypervisor_uuid attribute to ComputeNodes model object (this includes a new column on compute_nodes)
 * populate hypervisor_uuid via the libvirt driver's existing get_host_uuid method
 * return hypervisor_uuid with other hypervisor details via the API calls under /os-hypervisors.

This feature requires no permission changes, it is adding a field to an existing API.

An example call would be to /v2/<tenant id>/os-hypervisors/<hypervisor id> which would return something like this:

{
    "hypervisor": {
        "hypervisor_hostname": "devstack.novalocal",
        "hypervisor_uuid": "7bc268e4-6a94-4e6e-9b54-b88958ae7998",
        "id": 1,
        <existing additional details here>
    }
}

CLI calls to "nova hypervisor-show <id>" would output this additional field as well, no changes to python-novaclient are needed.

Specification URL (additional information):

None