.\" This manpage has been automatically generated by docbook2man
.\" from a DocBook document. This tool can be found at:
.\"
.\" Please send any bug reports, improvements, comments, patches,
.\" etc. to Steve Cheng .
.TH "NBDTAB" "5" "$Date: 2006-10-18 15:01:57 +0200 (wo, 18 okt 2006) $" "" ""
.SH NAME
/etc/nbdtab \- configuration file for nbd-client
.SH SYNOPSIS
\fB/etc/nbdtab \fR
.SH "DESCRIPTION"
.PP
This file allows to configure predefined connections for
nbd-client. It may contain multiple definitions, one per line,
each of which contains four space-separated fields.
.PP
To connect a device specified in the nbdtab file,
run \fBnbd-client\fR(8) with the short name of that
device as the sole argument. It will then look up the required
information in \fInbdtab\fR, and make the
connection.
.PP
Fields are separated from one another by any number of space
or tab characters; records are separated from one another by
newline characters. The file may also contain any number of
comments, which start with a '#' character and continue until the
end of the line or the end of the file, whichever is first.
.SS "FIELDS"
.PP
The file contains the following fields:
.TP 3
1.
The short name of the device file. That is, it should
contain the name of the device without the leading
\fI/dev/\fR part; e.g., it could say
\fInbd0\fR\&.
.TP 3
2.
The hostname (in case of a TCP socket) or filename (in
case of a unix domain socket) on which the server is
listening.
.TP 3
3.
The name of the export as exported by
\fBnbd-server\fR\&.
.TP 3
4.
Any extra options. This field is optional (no pun
intended), and need not appear in a file if no options are
necessary. The options recognized by
\fBnbd-client\fR(8) are specified below, in the
section "Options". Any unknown options in
this field will produce a warning by
\fBnbd-client\fR, unless they are prepended by
an underscore ('_') character; the underscore is
specifically reserved for local use, or for distribution
customization.
.SS "OPTIONS"
.PP
Every command-line \fBnbd-client\fR option
which allows to configure specific options for a particular
device node has a corresponding option in the
\fInbdtab\fR file, and vice versa; where this
isn't the case, that is a bug.
.PP
Individual options in this field should be separated from
one another by the comma character.
.TP
\fBbs=\fIblock size\fB\fR
The block size for this export. If this option is
not used, the kernel's default will be used
instead.
Corresponds to the \fB-b\fR option on the
command line.
.TP
\fBcacertfile=\fIcertificate file\fB\fR
The CA certificate file for TLS. Corresponds to the
\fB-A\fR option on the command line.
.TP
\fBcertfile=\fIcertificate file\fB\fR
The certificate file for TLS. Corresponds to the
\fB-F\fR option on the command line.
.TP
\fBconns=\fInumber\fB\fR
The number of connections to use for this device.
Corresponds to the \fB-C\fR option on the command
line; see nbd-client(8) for more details on that
option.
.TP
\fBkeyfile=\fIkey file\fB\fR
The private key file for TLS. Corresponds to the
\fB-K\fR option on the command line.
.TP
\fBno_optgo\fR
Disable the use of NBD_OPT_GO in the conversation.
Corresponds to the \fB-g\fR option on the command
line.
.TP
\fBpersist\fR
Persist the connection, using the semantics of the
\fB-p\fR command-line option.
.TP
\fBport=\fIport number\fB\fR
The port on which to communicate with the
\fBnbd-server\fR\&. Defaults to the
IANA-assigned port for NBD, 10809.
.TP
\fBpriority=\fIGnuTLS priority string\fB The GnuTLS priority string to use. Corresponds to the -y option on the command line. \fR
.TP
\fBswap\fR
Optimize for swap; \fB-s\fR\&.
.TP
\fBtimeout=\fItimeout\fB\fR
The timeout. If this option is not specified, no
timeout is configured.
Corresponds to the \fB-t\fR option on the
command line.
.TP
\fBtlshostname=\fITLS hostname\fB\fR
The hostname for TLS purposes;
\fB-H\fR
.TP
\fBunix\fR
Use a Unix Domain socket to connect to the server;
\fB-u\fR\&.
.SH "SEE ALSO"
.PP
nbd-server (1), nbd-client (8), nbd-trdump (8)
.SH "AUTHOR"
.PP
The NBD kernel module and the NBD tools were originally
written by Pavel Machek (pavel@ucw.cz)
.PP
The Linux kernel module is now maintained by Paul Clements
(Paul.Clements@steeleye.com), while the userland tools are
maintained by Wouter Verhelst ()
.PP
On The Hurd there is a regular translator available to perform the
client side of the protocol, and the use of
\fBnbd-client\fR is not required. Please see the
relevant documentation for more information.
.PP
This manual page was written by Wouter Verhelst ().
Permission is granted to copy, distribute and/or modify this
document under the terms of the GNU General
Public License, version 2, as published by the Free Software
Foundation.
.SH "EXAMPLES"
.PP
A simple \fInbdtab\fR file could look like
this:
.nf
# swap space, called "swapexport" on the server
# optimize for swap, and try to reconnect upon disconnect.
nbd0 nbdserver.example.com swapexport swap,persist
# other export, called "data" on the server. No options for this one.
nbd1 nbdserver.example.com data
.fi