[pve-devel] [PATCH guest-common/container/qemu-server v2] improve snapshot rollback
Dominik Csapak
d.csapak at proxmox.com
Fri Sep 14 14:08:39 CEST 2018
this series moves the qemu specific rollback code to qemu-server
(where it belongs), and fixes an odd behaviour in the snapshot logic regarding
machine type
it does this by introducing a rollback hook which gets called twice during
rollback and allow for data to be passed between calls
this data then gets passed to the vm_start method (if vmstate is present)
the qemu-server patches contain a workaround, so that they do not
rely on a new guest-common, which makes the dependency handling better
(guest-common needs a break on old qemu-server version, but the
new qemu-server does not need the new guest-common)
this series will be necessary for my upcoming vmgenid patches
(which uses the rollback hook)
changes from v1:
* reworded comments
* make machine to a standard option
* removed workaround, now needs versioned dependecy:
next qemu-server needs dependecy of guest-common+1
next guest-common needs a breaks current qemu-server
pve-guest-common:
Dominik Csapak (1):
add rollback hook and remove qemu machine code
PVE/AbstractConfig.pm | 31 +++++++++++++++----------------
1 file changed, 15 insertions(+), 16 deletions(-)
pve-container:
Dominik Csapak (1):
rename forcemachine
src/PVE/LXC/Config.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
qemu-server:
Dominik Csapak (3):
add forcemachine rollback code
improve snapshot machine logic
add new tests for 'runningmachine' and rollback
PVE/QemuConfig.pm | 35 ++++++++++++++++++----
PVE/QemuServer.pm | 21 ++++++++-----
test/snapshot-expected/create/qemu-server/102.conf | 2 +-
test/snapshot-expected/create/qemu-server/104.conf | 2 +-
test/snapshot-expected/create/qemu-server/106.conf | 2 +-
test/snapshot-expected/create/qemu-server/301.conf | 33 ++++++++++++++++++++
test/snapshot-expected/create/qemu-server/302.conf | 33 ++++++++++++++++++++
.../snapshot-expected/prepare/qemu-server/102.conf | 2 +-
.../snapshot-expected/prepare/qemu-server/104.conf | 2 +-
.../rollback/qemu-server/301.conf | 33 ++++++++++++++++++++
.../rollback/qemu-server/302.conf | 35 ++++++++++++++++++++++
test/snapshot-input/create/qemu-server/301.conf | 13 ++++++++
test/snapshot-input/create/qemu-server/302.conf | 13 ++++++++
test/snapshot-input/rollback/qemu-server/301.conf | 33 ++++++++++++++++++++
test/snapshot-input/rollback/qemu-server/302.conf | 34 +++++++++++++++++++++
test/snapshot-test.pm | 10 ++++++-
16 files changed, 284 insertions(+), 19 deletions(-)
create mode 100644 test/snapshot-expected/create/qemu-server/301.conf
create mode 100644 test/snapshot-expected/create/qemu-server/302.conf
create mode 100644 test/snapshot-expected/rollback/qemu-server/301.conf
create mode 100644 test/snapshot-expected/rollback/qemu-server/302.conf
create mode 100644 test/snapshot-input/create/qemu-server/301.conf
create mode 100644 test/snapshot-input/create/qemu-server/302.conf
create mode 100644 test/snapshot-input/rollback/qemu-server/301.conf
create mode 100644 test/snapshot-input/rollback/qemu-server/302.conf
--
2.11.0
More information about the pve-devel
mailing list