Node Libvirt Unique UUID Not Generated On Deployment

Bug #1378962 reported by Tyler Wilson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
Medium
Oleksiy Molchanov
5.1.x
Fix Released
Medium
Oleksiy Molchanov
puppet-nova
Fix Released
Undecided
Oleksiy Molchanov

Bug Description

Some SuperMicro (And I am sure other Motherboard makers) do not have unique UUID's in 'virsh sysinfo' and thus things such as Live Migrations will fail.

[root@fuel01 ~]# ssh node-22
root@node-22:~# virsh sysinfo | grep uuid
    <entry name='uuid'>00000000-0000-0000-0000-002590C7DB9A</entry>
[root@fuel01 ~]# ssh node-21
root@node-21:~# virsh sysinfo | grep uuid
    <entry name='uuid'>00000000-0000-0000-0000-002590C4CBA6</entry>
[root@fuel01 ~]# ssh node-20
root@node-20:~# virsh sysinfo | grep uuid
    <entry name='uuid'>00000000-0000-0000-0000-002590C7D9D4</entry>
[root@fuel01 ~]# ssh node-19
root@node-19:~# virsh sysinfo | grep uuid
    <entry name='uuid'>00000000-0000-0000-0000-002590C4CBA6</entry>

Note how node-19 and node-21 have the same UUID (even though they are separate blades in different chassis), I will be opening an issue with SuperMicro independently however It is unwise to trust that hardware vendors will supply a unique UUID. A simple fix is the following;

echo "host_uuid = \"`uuidgen`\"" >> /etc/libvirt/libvirtd.conf

and then restarting the libvirt service;

service libvirt-bin restart

Tyler Wilson (loth)
description: updated
Changed in fuel:
milestone: none → 6.0
status: New → Confirmed
importance: Undecided → Medium
assignee: nobody → Fuel Library Team (fuel-library)
Changed in fuel:
status: Confirmed → Triaged
tags: added: low-hanging-fruit
Changed in fuel:
assignee: Fuel Library Team (fuel-library) → Oleksiy Molchanov (omolchanov)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (master)

Fix proposed to branch: master
Review: https://review.openstack.org/128640

Changed in fuel:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (master)

Reviewed: https://review.openstack.org/128640
Committed: https://git.openstack.org/cgit/stackforge/fuel-library/commit/?id=63636d115190ec1b07ee8ea77906fd6bd2f4c576
Submitter: Jenkins
Branch: master

commit 63636d115190ec1b07ee8ea77906fd6bd2f4c576
Author: Oleksiy Molchanov <email address hidden>
Date: Wed Oct 15 16:10:50 2014 +0300

    Add host_uuid to libvirtd.conf

    Add host_uuid generated by uuidgen to libvirtd.conf

    Change-Id: I238652e0a42fc3e15fd6cf7416343fb900336784
    Closes-Bug: 1378962

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
Dennis Dmitriev (ddmitriev) wrote :

Looks like the host_uuid parameter of the config /etc/libvirt/libvirtd.conf doesn't work at all:

======================== On Supermicro/X9DRW (ubuntu):
(devops-venv)root@srv09-kha:/etc/libvirt# cat /etc/libvirt/libvirtd.conf | grep host_uuid
#host_uuid = "00000000-0000-0000-0000-000000000000"
host_uuid = "3e0f026b-b318-4eb8-a5f9-f53cae32caa9"

(devops-venv)root@srv09-kha:/etc/libvirt# /etc/init.d/libvirt-bin restart
 * Restarting libvirt management daemon /usr/sbin/libvirtd [ OK ]

(devops-venv)root@srv09-kha:/etc/libvirt# virsh sysinfo | grep uuid
    <entry name='uuid'>00000000-0000-0000-0000-0025909A5946</entry>

======================== On virtual environment (verified on ubuntu and centos):
root@node-4:/etc/libvirt# cat /etc/libvirt/libvirtd.conf | grep host_uuid
#host_uuid = "00000000-0000-0000-0000-000000000000"
host_uuid = "3e0f026b-b318-4eb8-a5f9-f53cae32caa9"

root@node-4:/etc/libvirt# service libvirt-bin restart
libvirt-bin stop/waiting
libvirt-bin start/running, process 23201

root@node-4:/etc/libvirt# virsh sysinfo |grep 'uuid'
    <entry name='uuid'>3DA3363F-701F-4124-98A6-2AFE12D44873</entry>

root@node-4:/etc/libvirt# dmidecode -t system |grep UUID
 UUID: 3DA3363F-701F-4124-98A6-2AFE12D44873
=====================================================================

Restart of the server / node with modified config file doesn't help.

Changed in fuel:
status: Fix Committed → Confirmed
Revision history for this message
Dennis Dmitriev (ddmitriev) wrote :

UPD: The config parameter 'host_uuid' changes the different host UUID:

$ virsh capabilities | grep uuid

Thus, `virsh sysinfo` always returns a hardware defined UUID, and `virsh capabilities` returns a custom configured UUID.

Revision history for this message
Dennis Dmitriev (ddmitriev) wrote :

Patch is working as expected.

Changed in fuel:
status: Confirmed → Fix Committed
Changed in puppet-nova:
assignee: nobody → Oleksiy Molchanov (omolchanov)
status: New → In Progress
status: In Progress → New
Changed in puppet-nova:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (stable/5.1)

Fix proposed to branch: stable/5.1
Review: https://review.openstack.org/131770

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (stable/5.1)

Reviewed: https://review.openstack.org/131770
Committed: https://git.openstack.org/cgit/stackforge/fuel-library/commit/?id=79c4d5dda8e7a4c104804aba3836b13e1edef343
Submitter: Jenkins
Branch: stable/5.1

commit 79c4d5dda8e7a4c104804aba3836b13e1edef343
Author: Oleksiy Molchanov <email address hidden>
Date: Wed Oct 15 16:10:50 2014 +0300

    Add host_uuid to libvirtd.conf

    Add host_uuid generated by uuidgen to libvirtd.conf

    Change-Id: I238652e0a42fc3e15fd6cf7416343fb900336784
    Closes-Bug: 1378962

Revision history for this message
Dennis Dmitriev (ddmitriev) wrote :

Released on 5.1.1:
{u'build_id': u'2014-12-03_01-07-36', u'ostf_sha': u'64cb59c681658a7a55cc2c09d079072a41beb346', u'build_number': u'48', u'auth_required': True, u'nailgun_sha': u'500e36d08a45dbb389bf2bd97673d9bff48ee84d', u'production': u'docker', u'api': u'1.0', u'fuelmain_sha': u'7626c5aeedcde77ad22fc081c25768944697d404', u'astute_sha': u'ef8aa0fd0e3ce20709612906f1f0551b5682a6ce', u'feature_groups': [u'mirantis'], u'release': u'5.1.1', u'release_versions': {u'2014.1.3-5.1.1': {u'VERSION': {u'build_id': u'2014-12-03_01-07-36', u'ostf_sha': u'64cb59c681658a7a55cc2c09d079072a41beb346', u'build_number': u'48', u'api': u'1.0', u'nailgun_sha': u'500e36d08a45dbb389bf2bd97673d9bff48ee84d', u'production': u'docker', u'fuelmain_sha': u'7626c5aeedcde77ad22fc081c25768944697d404', u'astute_sha': u'ef8aa0fd0e3ce20709612906f1f0551b5682a6ce', u'feature_groups': [u'mirantis'], u'release': u'5.1.1', u'fuellib_sha': u'a3043477337b4a0a8fd166dc83d6cd5d504f5da8'}}}, u'fuellib_sha': u'a3043477337b4a0a8fd166dc83d6cd5d504f5da8'}

Revision history for this message
Dennis Dmitriev (ddmitriev) wrote :

Released on 6.0:
api: '1.0'
astute_sha: 16b252d93be6aaa73030b8100cf8c5ca6a970a91
auth_required: true
build_id: 2014-12-07_22-41-06
build_number: '43'
feature_groups:
- mirantis
fuellib_sha: 3e1f23e042ea8f4f25b6bf956aca17e29e57e708
fuelmain_sha: 134f70e8332d9a52f17565e23e8b14f092efb735
nailgun_sha: 73a2fa3aa669ca8d95788e80dc052dfa16eca24a
ostf_sha: a9afb68710d809570460c29d6c3293219d3624d4
production: docker
release: '6.0'
release_versions:
  2014.2-6.0:
    VERSION:
      api: '1.0'
      astute_sha: 16b252d93be6aaa73030b8100cf8c5ca6a970a91
      build_id: 2014-12-07_22-41-06
      build_number: '43'
      feature_groups:
      - mirantis
      fuellib_sha: 3e1f23e042ea8f4f25b6bf956aca17e29e57e708
      fuelmain_sha: 134f70e8332d9a52f17565e23e8b14f092efb735
      nailgun_sha: 73a2fa3aa669ca8d95788e80dc052dfa16eca24a
      ostf_sha: a9afb68710d809570460c29d6c3293219d3624d4
      production: docker
      release: '6.0'

Changed in fuel:
status: Fix Committed → Fix Released
Revision history for this message
Emilien Macchi (emilienm) wrote :

is the fix in puppet-nova still in progress? Please update this bug so we can maybe fix it upstream.

Thanks

Changed in puppet-nova:
assignee: Oleksiy Molchanov (omolchanov) → Dmitry Ilyin (idv1985)
Changed in puppet-nova:
assignee: Dmitry Ilyin (idv1985) → Oleksiy Molchanov (omolchanov)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to puppet-nova (master)

Reviewed: https://review.openstack.org/131710
Committed: https://git.openstack.org/cgit/openstack/puppet-nova/commit/?id=8bf30c41e90f1571630e8b77f3c97f85328f9e5f
Submitter: Jenkins
Branch: master

commit 8bf30c41e90f1571630e8b77f3c97f85328f9e5f
Author: Oleksiy Molchanov <email address hidden>
Date: Wed Oct 29 13:20:18 2014 +0200

    Add host_uuid to libvirtd.conf

    Add host_uuid generated by uuidgen to libvirtd.conf

    Change-Id: Ib060bff4b1f547b4db255969bc8cb3119a85ba6d
    Closes-Bug: 1378962

Changed in puppet-nova:
status: In Progress → Fix Released
Revision history for this message
Fuel Devops McRobotson (fuel-devops-robot) wrote : Fix proposed to puppet-modules/puppet-nova (mos-9.0)

Fix proposed to branch: mos-9.0
Change author: Oleksiy Molchanov <email address hidden>
Review: https://review.fuel-infra.org/17018

Revision history for this message
Fuel Devops McRobotson (fuel-devops-robot) wrote : Change abandoned on puppet-modules/puppet-nova (mos-9.0)

Change abandoned by Ivan Berezovskiy <email address hidden> on branch: mos-9.0
Review: https://review.fuel-infra.org/17018

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.