[Top][All Lists]

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

[Qemu-devel] Re: NBD server for QEMU images

From: Salvador Fandino
Subject: [Qemu-devel] Re: NBD server for QEMU images
Date: Tue, 12 Dec 2006 18:32:17 +0100
User-agent: Icedove (X11/20061128)

Anthony Liguori wrote:
> Salvador FandiƱo wrote:
>> Hi,
>> The patch available from http://qemu-forum.ipi.fi/viewtopic.php?t=2718
>> adds a new utility, qemu-nbds, that implements a NBD server (see
>> http://nbd.sf.net) for QEMU images.
>> Using this utility it is posible to mount images in any format
>> supported by QEMU.
>> Unfortunatelly, only read access works (locally) due to a limitation
>> on the Linux Kernel :-(
> http://hg.codemonkey.ws/qemu-nbd/
> And write access works for me.  What's this limitation you speak of?

Mounting a partition being served on the same host as read-write can
cause deadlocks. From nbd-2.9.0 README file:

"When you write something to a block device, the kernel will not
immediately write that to the physical block device; instead, your
changes are written to a cache, which is periodically flushed by a
kernel thread, 'kblockd'. If you're using a single-processor system,
then you'll have only one kblockd, meaning, the kernel can't write to
more than one block device at the same time.

If, while your kblockd is emptying the NBD buffer cache, the kernel
decides that the cache of the block device your nbd-server is writing to
needs to be emptied, then you've got a deadlock."


 - Salva

reply via email to

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