[libvirt] [RFC] move host uuid out of libvirtd.conf (effectively)

Daniel P. Berrange berrange at redhat.com
Fri Apr 22 13:51:16 UTC 2016


On Fri, Apr 22, 2016 at 04:36:04PM +0300, Nikolay Shirokovskiy wrote:
> Hi, all. I hope RFC flow from me are not hitting some rate limiting.
> 
>  Integration tests in our compary undercover that host uuid provided thru dmi
> is not as unique as it should be. This is probably a manufacturer mistake but
> still the case.
> 
>  Here libvirt's config field host uuid comes to the rescue. It is a good option
> in case of tweaking a few machines. In case of full-fledged mgmt it is probably
> enough too. But in case your managment is managment of packages thru you
> package manager it is not that convinent. The problem is that if one generates
> uuid on package install then package update will not be easy. One probably
> wants for updates to go smoothly in case user does not tweak anything but now
> it is not possible as changing host uuid is visible as user intervention by
> package managment. I'm talking now from my rpm based managment experience but
> I imagine this could be no different in other packaging systems too. This is
> probably could be overcomed thru some kind of reserse patching before update
> and patching again after if package system is wise enougth to check file hashes
> and not timestamps for example. But then this is should be done in this and
> every packaging system.
> 
>  So my proposition is simple - make it possible to take host uuid from distinct
> file. I think keeping uuid could be the sole purpuse of it. Then we can 
> generate uuid on package installation and later updates need no any extra
> actions at all.
> 
>  Another benefit of keeping uuid in distinct place is that one can just copy
> daemon configuration to a different host not being aware it needs to be
> changed.

We have an open todo item to make it possible to use /etc/machine-id as
an alternative

   https://bugzilla.redhat.com/show_bug.cgi?id=864564

For upgrade compatibility we can't change the default behaviour of
libvirtd, so we'd want to add a config param to libvirtd.conf which
said  host_uuid_source="smbios|machine-id"  and let deployments set
it to machine-id if desired.

Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|




More information about the libvir-list mailing list