[libvirt] [PATCH] [RFC] xen-xm: Generate UUID if not specified

I received a bug report about 'virsh domxml-from-native xen-xm' failing when the xm configuration does not contain a UUID. IMO, this is a bit harsh since UUID is not even required when defining a domain. I first took the approach of skipping the parsing of UUID when it is not specified in the xm config, but that results in a UUID of all zeros, which is the dom0 UUID from the xen tools perspective. I'd like to hear what other folks think about the attached patch, which generates a UUID if it is not specified in the xm config. Regards, Jim

On 08/03/2012 03:32 PM, Jim Fehlig wrote:
I received a bug report about 'virsh domxml-from-native xen-xm' failing when the xm configuration does not contain a UUID. IMO, this is a bit harsh since UUID is not even required when defining a domain.
Agreed.
I first took the approach of skipping the parsing of UUID when it is not specified in the xm config, but that results in a UUID of all zeros, which is the dom0 UUID from the xen tools perspective.
I'd like to hear what other folks think about the attached patch, which generates a UUID if it is not specified in the xm config.
Makes sense to me; you have my: ACK. -- Eric Blake eblake@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org

Eric Blake wrote:
On 08/03/2012 03:32 PM, Jim Fehlig wrote:
I received a bug report about 'virsh domxml-from-native xen-xm' failing when the xm configuration does not contain a UUID. IMO, this is a bit harsh since UUID is not even required when defining a domain.
Agreed.
I first took the approach of skipping the parsing of UUID when it is not specified in the xm config, but that results in a UUID of all zeros, which is the dom0 UUID from the xen tools perspective.
I'd like to hear what other folks think about the attached patch, which generates a UUID if it is not specified in the xm config.
Makes sense to me; you have my:
ACK.
Thanks Eric, pushed now. Regards, Jim
participants (2)
-
Eric Blake
-
Jim Fehlig