cockpit-machines icon indicating copy to clipboard operation
cockpit-machines copied to clipboard

snapshots: Allow disk-only snapshots of running machines

Open mvollmer opened this issue 10 months ago • 9 comments

  • [x] Use "Full system" instead of "Complete". That's the libvirt terminology.
  • [x] Detect guest agent and add "quiesce" flag is found.
  • [x] Test quiesce functionality.... Maybe switch from cirros to alpine, which has qemu-guest-agent

image

image

image

mvollmer avatar Apr 16 '24 11:04 mvollmer

I wasn't able to revert to a disk-only snapshot:

image

Probably tracked by https://issues.redhat.com/browse/RHEL-21549 and fixed by https://www.mail-archive.com/[email protected]/msg01703.html, but not yet in rhel-9-4.

Should this feature here go to rhel-9-4 or be put on hold until rhel-9-5?

mvollmer avatar Apr 16 '24 11:04 mvollmer

Should this feature here go to rhel-9-4 or be put on hold until rhel-9-5?

Alright, current "main" goes to rhel-9-5 already, this is good to go.

mvollmer avatar Apr 16 '24 11:04 mvollmer

I should've used the term "disk-only" instead of "partial" in the code, but I figured out too late that that's what libvirt calls them.

mvollmer avatar Apr 16 '24 11:04 mvollmer

I should've used the term "disk-only" instead of "partial" in the code, but I figured out too late that that's what libvirt calls them.

Fixed.

mvollmer avatar Apr 16 '24 11:04 mvollmer

This is blocked on https://issues.redhat.com/browse/RHEL-21549

Cockpit should only offer the creation of disk-only external snapshots when they can also be restored. We might have to detect that at run-time, maybe by looking at the libvirt version.

mvollmer avatar Apr 16 '24 14:04 mvollmer

For the record: I will never approve this, this is a dangerous and crazy practice to offer and train admins to do. I won't make a fuss if someone else approves, but I refuse any responsibility for this, sorry.

martinpitt avatar Apr 23 '24 13:04 martinpitt

I wasn't able to revert to a disk-only snapshot:

Hmm, reverting disk-only snapshots might not be that important. Maybe they are only used as a mechanism to get a stable view of disks for the purposes of backup. If that is the case, I would argue that Cockpit doesn't need to offer disk-only snapshots. Completing the backup requires a deep understanding of how external snapshots are implemented and this is best done on the command line or from a program.

mvollmer avatar May 13 '24 10:05 mvollmer

Completing the backup requires a deep understanding of how external snapshots are implemented and this is best done on the command line or from a program.

What Cockpit could do is to expose the snapshotted disks as NBD devices so that people can then copy them to their backups.

mvollmer avatar May 13 '24 10:05 mvollmer

I mentioned on another thread here that I in fact did break a VM fiddling with the snapshots. I received additional instructions and will do another test shortly. I understand that documentation has been added to the Redhat 9.4 release but I made a suggestion that documentation could be added via the GUI with a popup link that could at a minimum provide a link to documentation on the web, image

mac2net avatar May 15 '24 09:05 mac2net

This is dead for now. No disk-only snapshots of running VMs in Cockpit, see https://issues.redhat.com/browse/COCKPIT-1112

mvollmer avatar May 29 '24 14:05 mvollmer