qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Disable image locking for snapshot drive?


From: John Snow
Subject: Re: [Qemu-devel] Disable image locking for snapshot drive?
Date: Mon, 17 Jul 2017 20:33:55 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1


On 07/17/2017 07:30 PM, Andrew Baumann via Qemu-devel wrote:
> Hi all,
> 
> I'm running a recent Linux build of qemu on Windows Subsystem for Linux (WSL) 
> which doesn't appear to implement file locking:
> 
> $ qemu-system-aarch64 ... -drive file=test.vhdx,if=none,id=hd0 -device 
> virtio-blk-pci,drive=hd0
> qemu-system-aarch64: -drive file=test.vhdx,if=none,id=hd0: Failed to unlock 
> byte 100
> qemu-system-aarch64: -drive file=test.vhdx,if=none,id=hd0: Failed to unlock 
> byte 100
> qemu-system-aarch64: -drive file=test.vhdx,if=none,id=hd0: Failed to lock 
> byte 100
> 
> That's no big deal; I can switch it off:
> 
> $ qemu-system-aarch64 ... -drive 
> file=test.vhdx,if=none,file.locking=off,id=hd0 ...
> (all good)
> 
> But how can I do the same for a snapshot drive?
> 
> $ qemu-system-aarch64 ... -drive 
> file=test.vhdx,if=none,file.locking=off,id=hd0 -snapshot ...
> qemu-system-aarch64: -drive file=test.vhdx,if=none,file.locking=off,id=hd0: 
> Failed to unlock byte 100
> qemu-system-aarch64: -drive file=test.vhdx,if=none,file.locking=off,id=hd0: 
> Failed to unlock byte 100
> qemu-system-aarch64: -drive file=test.vhdx,if=none,file.locking=off,id=hd0: 
> Could not create temporary overlay '/var/tmp/vl.o83dxn': Failed to lock byte 
> 100
> 
> (I also tried the snapshot=on drive option with similar results.)
> 
> Thanks,
> Andrew
> 

Looks like the shorthand "-snapshot" doesn't let you specify any further
options, which is a bummer.

You may need to do something a little more manual, and create your own
temporary overlay, and launch QEMU pointing to that overlay instead.

That sounds like a bit of a hassle.

Can we compile locking support out of QEMU instead for this platform? Or
is there a runtime option for disabling it globally?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]