On Fri, Jan 28, 2022 at 12:39:11PM +0100, Hanna Reitz wrote: > So I actually don’t know why it works for you. OTOH, I don’t > understand why the block size affects you over NBD, because I would > have expected qemu to internally auto-align requests when they are > not aligned (in bdrv_co_pwritev_part()).
I checked it again and my hack definitely fixes nbdcopy. But maybe that's expected if qemu-nbd is auto-aligning requests? (I'm only accessing the block layer through qemu-nbd, not with qemu-io) > Like, when I set the NBD > block driver’s alignment to 512[2], the following still succeeds: Did you just patch that line in the code or is there a qemu-nbd option/image-opts to do this? Rich. > [1] https://gitlab.com/qemu-project/qemu/-/blob/master/block/qcow2.c#L4662 > [2] https://gitlab.com/qemu-project/qemu/-/blob/master/block/nbd.c#L1918 -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows programs, test, and build Windows installers. Over 100 libraries supported. http://fedoraproject.org/wiki/MinGW