On Wed, Mar 20, 2019 at 11:39:01 -0500, Eric Blake wrote:
On 3/20/19 3:16 AM, Christian Ehrhardt wrote:
>> So looking at the bug, user created a snapshot, then upgraded qemu to a
>> version which dropped the old machine type.
>>
>> Reverting to a inactive internal snapshot in this case will restore the
>> definition including the machine type. That is what snapshots are
>> expected to do.
We already have a FORCE flag for virDomainSnapshotRevert(); is that not
sufficient to allow reverting to an inactive snapshot where the domain
description is no longer viable in modern qemu? I'm trying to see why a
second --force flag to create --redefine helps things.
In the bug description the virDomainSnapshotRevert call succeessfully
reverted the state. Since the snapshot was taken in inactive state the
VM was stopped. A subsequent 'virsh start' failed and reported that the
machine type which was recorded was no longer suppored.
The ABI stability check which is done a part of redefining the snapshot
via 'virsh snapshot-edit' failed.
Even if the ABI stability check would be overriden, a 'virsh start'
would still fail until reverting to the snapshot again.
In this case the configuration can be simply fixed by editing the
current configuration after reverting the snapshpot by 'virsh edit'.
While that does not allow to fix snapshots which were not reverted to
I'm arguing that having the force flag is not required. This also does
avoid potential other problems which users could inflict on themselves
by forcing config without thinking.