Lines Matching +full:- +full:- +full:-
1 .. _qemu-nbd:
8 --------
10 **qemu-nbd** [*OPTION*]... *filename*
12 **qemu-nbd** -L [*OPTION*]...
14 **qemu-nbd** -d *dev*
17 -----------
23 - Bind a /dev/nbdX block device to a QEMU server (on Linux).
24 - As a client to query exports of a remote NBD server.
27 -------
29 .. program:: qemu-nbd
32 driver options if :option:`--image-opts` is specified.
36 .. option:: --object type,id=ID,...
42 keys, and the ``tls-creds`` object, which is used to supply TLS
43 credentials for the ``qemu-nbd`` server or client.
45 .. option:: -p, --port=PORT
50 .. option:: -o, --offset=OFFSET
54 .. option:: -b, --bind=IFACE
59 .. option:: -k, --socket=PATH
63 .. option:: --image-opts
66 filename. If this flag is specified, the ``-f`` flag should
69 .. option:: -f, --format=FMT
72 auto-detecting.
74 .. option:: -r, --read-only
76 Export the disk as read-only.
78 .. option:: -A, --allocation-depth
81 ``qemu:allocation-depth`` metadata context accessible through
84 .. option:: -B, --bitmap=NAME
87 that bitmap via the ``qemu:dirty-bitmap:NAME`` metadata context
90 .. option:: -s, --snapshot
96 .. option:: -l, --load-snapshot=SNAPSHOT_PARAM
99 as an read-only device, SNAPSHOT_PARAM format is
102 .. option:: --cache=CACHE
107 the emulator's ``-drive cache=...`` option for more info.
109 .. option:: -n, --nocache
111 Equivalent to :option:`--cache=none`.
113 .. option:: --aio=AIO
118 .. option:: --discard=DISCARD
125 .. option:: --detect-zeroes=DETECT_ZEROES
128 driver-specific optimized zero write commands. *DETECT_ZEROES* is one of
133 .. option:: -c, --connect=DEV
137 .. option:: -d, --disconnect
141 .. option:: -e, --shared=NUM
146 .. option:: -t, --persistent
150 .. option:: -x, --export-name=NAME
152 Set the NBD volume export name (default of a zero-length string).
154 .. option:: -D, --description=DESCRIPTION
156 Set the NBD volume export description, as a human-readable
159 .. option:: --handshake-limit=N
164 .. option:: -L, --list
169 :option:`--export-name`, :option:`--offset`, ...).
171 .. option:: --tls-creds=ID
175 :option:`--object` option; or provide the credentials needed for
178 .. option:: --tls-hostname=hostname
185 to connect to the remote server, the :option:`--tls-hostname` option should
189 when acting as a NBD client with the :option:`--list` option.
191 .. option:: --fork
195 .. option:: --pid-file=PATH
199 .. option:: --tls-authz=ID
202 :option:`--object` option. This will be used to authorize connecting users
205 .. option:: -v, --verbose
208 *STDERR* stream open if the ``qemu-nbd`` process is daemonized due to
209 other options like :option:`--fork` or :option:`-c`.
211 .. option:: -h, --help
215 .. option:: -V, --version
219 .. option:: -T, --trace [[enable=]PATTERN][,events=FILE][,file=FILE]
221 .. include:: ../qemu-option-trace.rst.inc
224 --------
227 guest-visible contents of a qcow2 file, with no TLS encryption, and
229 one-shot, and will block until the first successful client
234 qemu-nbd -f qcow2 file.qcow2
236 Start a long-running server listening with encryption on port 10810,
242 qemu-nbd \
243 --object tls-creds-x509,id=tls0,endpoint=server,dir=/path/to/qemutls \
244 --object 'authz-simple,id=auth0,identity=CN=laptop.example.com,,\
246 --tls-creds tls0 --tls-authz auth0 \
247 -t -x subset -p 10810 \
248 --image-opts driver=raw,offset=1M,size=1M,file.driver=file,file.filename=file.raw
250 Serve a read-only copy of a guest image over a Unix socket with as
256 qemu-nbd --fork --persistent --shared=5 --socket=/path/to/sock \
257 --read-only --format=qcow2 file.qcow2
259 Expose the guest-visible contents of a qcow2 file via a block device
262 Access to bind ``qemu-nbd`` to a /dev/nbd device generally requires root
265 this method to mount filesystems from an untrusted guest image - a
271 qemu-nbd -c /dev/nbd0 -f qcow2 file.qcow2
272 qemu-nbd -d /dev/nbd0
279 qemu-nbd \
280 --object tls-creds-psk,id=tls0,dir=/tmp/keys,username=eblake,endpoint=client \
281 --tls-creds tls0 -L -b remote.example.com
284 --------
286 :manpage:`qemu(1)`, :manpage:`qemu-img(1)`