yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #06397
[Bug 1240542] Re: libvirt: the None value for the 'os_type' property is passed to glance when doing a snapshot
** Changed in: nova
Status: Fix Committed => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1240542
Title:
libvirt: the None value for the 'os_type' property is passed to glance
when doing a snapshot
Status in OpenStack Compute (Nova):
Fix Released
Bug description:
This change: https://review.openstack.org/42877 introduced the ability
to pass os_type property to glance when we are doing a snapshot, but
the change doesn't manage correctly the None value for this property.
The result of that is that we have a porperty called 'os_type': None associated with the snapshotted image.
That is a problem as this property is used when we create the backing file for the ephemeral disks.
From nova/virt/libvirt/driver/py:
# Lookup the filesystem type if required
os_type_with_default = instance['os_type']
if not os_type_with_default:
os_type_with_default = 'default'
and then we create the ephemeral file name using this rule:
fname = "ephemeral_%s_%s" % (ephemeral_gb, os_type_with_default)
Now consider an instance with a flavor with an ephemeral disk of 50 G and without the os_type defined, the resulting backing file will be:
"ephemeral_50_default"
At this point if we create a snapshot from that instance and we boot from it we will have another backing file created and called:
"ephemeral_50_None"
That is bad for at least two reasons:
1 performance issue: we need to create a new backing file which is not actually necessary
2 resources leaking: those backing files consume disk capacity on the host
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1240542/+subscriptions