Skip to content

Commit a3363f2

Browse files
RonnieSahlbergming1
authored andcommitted
MAN: Describe the NFS target in the manpage
Signed-off-by: Ronnie Sahlberg <rsahlberg@whamcloud.com>
1 parent 0e99759 commit a3363f2

2 files changed

Lines changed: 63 additions & 7 deletions

File tree

doc/ublk.1

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
.\" Title: ublk
33
.\" Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author]
44
.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
5-
.\" Date: 04/14/2025
5+
.\" Date: 04/27/2025
66
.\" Manual: ublk: manage ublk devices
77
.\" Source: ublk
88
.\" Language: English
99
.\"
10-
.TH "UBLK" "1" "04/14/2025" "ublk" "ublk: manage ublk devices"
10+
.TH "UBLK" "1" "04/27/2025" "ublk" "ublk: manage ublk devices"
1111
.\" -----------------------------------------------------------------
1212
.\" * Define some portability stuff
1313
.\" -----------------------------------------------------------------
@@ -36,7 +36,7 @@ ublk \- Utility to manage ublk devices
3636
.PP
3737
ublk is a utility that allows you to create, recover, view or delete user\-space block devices\&.
3838
.PP
39-
ublk by default comes with three different types of devices, null, loop and nbd\&.
39+
ublk by default comes with several different types of devices, such as nbd, nfs, null and loop\&.
4040
.PP
4141
The following commands are supported:
4242
.SH "ADD COMMAND"
@@ -47,7 +47,7 @@ Command to add a ublk device\&.
4747
.PP
4848
\fB\-t, \-\-type\fR
4949
.RS 4
50-
Specifies the type of device to create\&. The three types of supported devices are null, loop and bnd\&.
50+
Specifies the type of device to create\&. The four types of supported devices are nbd, nfs, null and loop\&.
5151
.RE
5252
.PP
5353
\fB\-n, \-\-number\fR
@@ -191,6 +191,32 @@ Use Zero\-Copy\&.
191191
.RS 4
192192
Read\-only device\&.
193193
.RE
194+
.SS "NFS"
195+
.PP
196+
Extra options for the nfs device type:
197+
.PP
198+
\fB add \-t nfs \&.\&.\&. \-\-nfs NFS\-URL \fR
199+
.PP
200+
\fB\-\-nfs NFS\-URL\fR
201+
.RS 4
202+
URL to tne NFS file to use as the block device\&.
203+
.sp
204+
The NFS\-URL format is describe in the libnfs README: https://github\&.com/sahlberg/libnfs/blob/9fa155bfa9d34347a669fbecf4a64259cc573724/README#L55
205+
.RE
206+
.PP
207+
Example: Create a nfs block device
208+
.sp
209+
.if n \{\
210+
.RS 4
211+
.\}
212+
.nf
213+
# ublk add \-t nfs \-n 0 \-\-nfs nfs://10\&.0\&.0\&.1/export/10M\&.raw
214+
215+
.fi
216+
.if n \{\
217+
.RE
218+
.\}
219+
.sp
194220
.SH "DEL COMMAND"
195221
.PP
196222
Command to delete a ublk device\&.

doc/ublk.1.xml

Lines changed: 33 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
ublk is a utility that allows you to create, recover, view or delete user-space block devices.
2626
</para>
2727
<para>
28-
ublk by default comes with three different types of devices, null, loop and nbd.
28+
ublk by default comes with several different types of devices, such as nbd, nfs, null and loop.
2929
</para>
3030
<para>
3131
The following commands are supported:
@@ -54,8 +54,8 @@
5454
<varlistentry><term><option>-t, --type</option></term>
5555
<listitem>
5656
<para>
57-
Specifies the type of device to create. The three types of supported
58-
devices are null, loop and bnd.
57+
Specifies the type of device to create. The four types of supported
58+
devices are nbd, nfs, null and loop.
5959
</para>
6060
</listitem>
6161
</varlistentry>
@@ -278,6 +278,36 @@
278278
</variablelist>
279279
</refsect2>
280280

281+
<refsect2><title>NFS</title>
282+
<para>
283+
Extra options for the nfs device type:
284+
</para>
285+
<para>
286+
<command>
287+
add -t nfs ... --nfs NFS-URL
288+
</command>
289+
</para>
290+
<variablelist>
291+
<varlistentry><term><option>--nfs NFS-URL</option></term>
292+
<listitem>
293+
<para>
294+
URL to tne NFS file to use as the block device.
295+
</para>
296+
<para>
297+
The NFS-URL format is describe in the libnfs README:
298+
https://github.com/sahlberg/libnfs/blob/9fa155bfa9d34347a669fbecf4a64259cc573724/README#L55
299+
</para>
300+
</listitem>
301+
</varlistentry>
302+
</variablelist>
303+
<para>
304+
Example: Create a nfs block device
305+
<screen format="linespecific">
306+
# ublk add -t nfs -n 0 --nfs nfs://10.0.0.1/export/10M.raw
307+
</screen>
308+
</para>
309+
</refsect2>
310+
281311
</refsect1>
282312

283313
<refsect1><title>DEL COMMAND</title>

0 commit comments

Comments
 (0)