yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #46526
[Bug 1547582] [NEW] Block migrating an ephemeral or swap disk can result in filesystem corruption when using qcow2
Public bug reported:
The libvirt driver uses common backing files for ephemeral and swap
disks. These are generated on the local compute host by running mkfs or
mkswap as appropriate. The output of these files for a particular size
and format is stored in the image cache on the compute host which ran
it.
When all things are equal, 2 runs of mkfs or mkswap are guaranteed never
to produce identical output, because at the very least they have
different uuids. When you also consider the potential for different
patch levels on different compute hosts, the potential for other
differences is also significant.
When block migrating an ephemeral disk, the libvirt driver copies the
'overlay' qcow2 from source to dest. Assuming that some other instance
on dest also has a similar ephemeral disk, the backing file will already
exist on dest. However, it is guaranteed not to be the same as the
disk's original backing file for the reasons above. If this works
currently, it is either by luck, or because the tiny amount of metadata
originally written by mkfs or mkswap is likely to have been overwritten
if it has been in use for any amount of time.
The libvirt driver should not cache the output of mkfs and mkswap. The
space and performance benefits are negligible, but it introduces the
potential for data corruption.
** Affects: nova
Importance: Undecided
Status: New
--
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/1547582
Title:
Block migrating an ephemeral or swap disk can result in filesystem
corruption when using qcow2
Status in OpenStack Compute (nova):
New
Bug description:
The libvirt driver uses common backing files for ephemeral and swap
disks. These are generated on the local compute host by running mkfs
or mkswap as appropriate. The output of these files for a particular
size and format is stored in the image cache on the compute host which
ran it.
When all things are equal, 2 runs of mkfs or mkswap are guaranteed
never to produce identical output, because at the very least they have
different uuids. When you also consider the potential for different
patch levels on different compute hosts, the potential for other
differences is also significant.
When block migrating an ephemeral disk, the libvirt driver copies the
'overlay' qcow2 from source to dest. Assuming that some other instance
on dest also has a similar ephemeral disk, the backing file will
already exist on dest. However, it is guaranteed not to be the same as
the disk's original backing file for the reasons above. If this works
currently, it is either by luck, or because the tiny amount of
metadata originally written by mkfs or mkswap is likely to have been
overwritten if it has been in use for any amount of time.
The libvirt driver should not cache the output of mkfs and mkswap. The
space and performance benefits are negligible, but it introduces the
potential for data corruption.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1547582/+subscriptions