Disable virtlockd

Felix Queißner felix at masterq32.de
Tue Jun 9 16:02:18 UTC 2020


> Yes. via the 'lock_manager' option in /etc/libvirt/qemu.conf
Okay, i'll read docs on this!

> 
>> or VM file locking? I
> 
> If you mean the image locking provided by qemu, then no, libvirt doesn't
> have provisions to disable it.
> 
>> start qemu with a -snapshot option which prevents and changes to the
>> disk image anyways.
> 
> Note that starting from libvirt-5.10 and qemu-4.2 any VM hacking in
> -snapshot via qemu:arg will break as '-snapshot' is not supported
> together with -blockdev which is used to configure disks.
> 
> This is because libvirt never really supported -snapshot.
> 
> Said that I still plan to add support for <transient/> disks but I'm
> currently busy with other features.
Okay, thanks for the information!


> You didn't really describe the problem though. Are you trying to share
> the disk images between multiple VMs?
> 
> Either way, another option is to add qcow2 overlay images which will
> capture the writes and discard them after the VM is turned off.
Yeah, the problem domain is this:
I have ~20 computer sharing the same properties (hardware up to device
revisions) and setup (as in hypervisor-os and user interaction).

They all require the exact same OS to be run AND require to be immutable
(so rebooting will reset them into the same state as before)

My current approach is having a disk image on NFS which i start with
libvirt+qemu and -snapshot. It does exactly what i need and if this is
not supported anymore i need a way to replace the behaviour (which is
"read from disk file, and cache+discard writes to the original image)

Using a distinct qcow2 image backed by the original image in /tmp should
work as well, if i understand right?

Regards
Felix




More information about the libvirt-users mailing list