aboutsummaryrefslogtreecommitdiff
path: root/qemu-doc.texi
diff options
context:
space:
mode:
authorths <ths@c046a42c-6fe2-441c-8c8c-71466251a162>2008-07-03 13:41:03 +0000
committerths <ths@c046a42c-6fe2-441c-8c8c-71466251a162>2008-07-03 13:41:03 +0000
commit75818250ba0f61d9e3008b11d8c63b7b46d80ba2 (patch)
tree10fdb06f655d82a6372bf918338f3de086895452 /qemu-doc.texi
parent3b05a8e91bf15e1858f3f3618069dbc78e55b88e (diff)
Allow QEMU to connect directly to an NBD server, by Laurent Vivier.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4838 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'qemu-doc.texi')
-rw-r--r--qemu-doc.texi35
1 files changed, 35 insertions, 0 deletions
diff --git a/qemu-doc.texi b/qemu-doc.texi
index 3e53d887cf..ec02685fc2 100644
--- a/qemu-doc.texi
+++ b/qemu-doc.texi
@@ -1321,6 +1321,7 @@ snapshots.
* qemu_nbd_invocation:: qemu-nbd Invocation
* host_drives:: Using host drives
* disk_images_fat_images:: Virtual FAT disk images
+* disk_images_nbd:: NBD access
@end menu
@node disk_images_quickstart
@@ -1503,6 +1504,40 @@ What you should @emph{never} do:
@item write to the FAT directory on the host system while accessing it with the guest system.
@end itemize
+@node disk_images_nbd
+@subsection NBD access
+
+QEMU can access directly to block device exported using the Network Block Device
+protocol.
+
+@example
+qemu linux.img -hdb nbd:my_nbd_server.mydomain.org:1024
+@end example
+
+If the NBD server is located on the same host, you can use an unix socket instead
+of an inet socket:
+
+@example
+qemu linux.img -hdb nbd:unix:/tmp/my_socket
+@end example
+
+In this case, the block device must be exported using qemu-nbd:
+
+@example
+qemu-nbd --socket=/tmp/my_socket my_disk.qcow2
+@end example
+
+The use of qemu-nbd allows to share a disk between several guests:
+@example
+qemu-nbd --socket=/tmp/my_socket --share=2 my_disk.qcow2
+@end example
+
+and then you can use it with two guests:
+@example
+qemu linux1.img -hdb nbd:unix:/tmp/my_socket
+qemu linux2.img -hdb nbd:unix:/tmp/my_socket
+@end example
+
@node pcsys_network
@section Network emulation