NVME-CONNECT-ALL(1) NVMe Manual NVME-CONNECT-ALL(1)

# [NAME](#NAME)

nvme-connect-all - Discover and Connect to Fabrics controllers.

# [SYNOPSIS](#SYNOPSIS)

```
nvme [<global-options>] connect-all


                        [--raw=<filename> | -r <filename>]


                        [--device=<device> | -d <device>]


                        [--config=<filename> | -J <cfg>]


                        [--persistent[=<no|auto|force>] | -p]


                        [--quiet]


                        [--no-reuse]


                        [--nbft]


                        [--no-nbft]


                        [--nbft-path=<STR>]


                        [--owner=<NAME>]


                        [<fabrics-options>]


                        [<global-options>]
```

# [DESCRIPTION](#DESCRIPTION)

Send one or more Discovery requests to a NVMe over Fabrics Discovery Controller, and create controllers for the returned discovery records.

If no parameters are given, then *nvme connect-all* will attempt to find a /usr/local/etc/nvme/discovery.conf file to use to supply a list of connect-all commands to run. If no /usr/local/etc/nvme/discovery.conf file exists, the command will quit with an error.

Otherwise a specific Discovery Controller should be specified using the --transport, --traddr and if necessary the --trsvcid and a Discovery request will be sent to the specified Discovery Controller.

See the documentation for the [nvme-discover(1)](/man/os/nvme-cli/nvme-discover.1) command for further background.

# [OPTIONS](#OPTIONS)

-r &lt;filename&gt;, --raw=&lt;filename&gt;

This field will take the output of the *nvme connect-all* command and dump it to a raw binary file. By default *nvme connect-all* will dump the output to stdout.

-d &lt;device&gt;, --device=&lt;device&gt;

This field takes a device as input. It must be a persistent device associated with a Discovery Controller previously created by the command "connect-all" or "discover". &lt;device&gt; follows the format nvme\*, eg. nvme0, nvme1.

-J &lt;filename&gt;, --config=&lt;filename&gt;

Use the specified JSON configuration file instead of the default /usr/local/etc/nvme/config.json file or *none* to not read in an existing configuration file. The JSON configuration file format is documented in **https://github.com/linux-nvme/nvme-cli/blob/master/libnvme/doc/config-schema.json**

-p, --persistent\[=&lt;no|auto|force&gt;]

Keep the discovery controller connected after retrieving the discovery log page, instead of disconnecting once it’s done. Because the value is optional, it must be attached directly to the option: --persistent=force for the long form, -pforce for the short form. A value given as a separate argument (--persistent force, -p force) is no value of the option but an extra argument, and the command fails.

•*no*: never persist. Use this to opt out of the default.

•*auto* (the default, both when the option is omitted entirely and when --persistent is given with no value): persist a Discovery Log Page entry’s connection only where that entry’s own EPCSD (Explicit Persistent Connection Support for Discovery) flag reports support for it; degrade to non-persistent, with a log message, for entries that don’t.

•*force*: persist regardless of what EPCSD reports, for a target whose self-reported EPCSD cannot be trusted.

*auto* and *force* ask each discovery controller for a keep-alive timeout of 30 seconds, or the --keep-alive-tmo value when it is given. *no* asks for none, even when --keep-alive-tmo is given.

--quiet

Suppress error messages.

--no-reuse

Always create a new connection, never reuse an existing one.

--nbft

Only look at NBFT tables

--no-nbft

Do not look at NBFT tables

--nbft-path=&lt;STR&gt;

Use a user-defined path to the NBFT tables

--owner=&lt;NAME&gt;

Record NAME as the owner of connected controllers in the NVMe ownership registry, so other orchestrators (and nvme-disconnect-all) leave them alone. See [nvme-disconnect-all(1)](/man/os/nvme-cli/nvme-disconnect-all.1). When --nbft is also given, --owner takes precedence over its default owner of *nbft*. An empty NAME (--owner=) removes the registry entries instead, leaving the controllers unowned. Without --owner, a controller that was already connected keeps the entry it has.

# [FABRICS OPTIONS](#FABRICS_OPTIONS)

The following options are common to NVMe over Fabrics commands such as nvme connect:

-a &lt;traddr&gt;, --traddr=&lt;traddr&gt;

Specify the network address of the controller. For transports using IP addressing (e.g. rdma, tcp), this should be an IP address.

--concat

Enable secure concatenation (TCP).

-c &lt;#&gt;, --reconnect-delay=&lt;#&gt;

Set the delay in seconds before reconnect is attempted after a connection loss.

-C &lt;secret&gt;, --kxchap-ctrl-secret=&lt;secret&gt;

Controller authentication secret for bi-directional authentication. If not specified, bi-directional authentication is not attempted.

-S &lt;secret&gt;, --kxchap-secret=&lt;secret&gt;

Host authentication secret (KX-HMAC-CHAP). Must be provided in ASCII format as defined in the NVMe specification.

-C &lt;secret&gt;, --dhchap-ctrl-secret=&lt;secret&gt;

Controller authentication secret for bi-directional authentication. If not specified, bi-directional authentication is not attempted. (deprecated, see --kxchap-ctrl-secret)

-S &lt;secret&gt;, --dhchap-secret=&lt;secret&gt;

Host authentication secret (DH-HMAC-CHAP). Must be provided in ASCII format as defined in the NVMe specification. (deprecated, see --kxchap-secret)

--disable-sqflow

Disable submission queue flow control.

-G, --data-digest

Enable data digest generation/verification (TCP).

-D, --duplicate-connect

Allow duplicate connections to the same subsystem.

-g, --hdr-digest

Enable header digest generation/verification (TCP).

-f &lt;iface&gt;, --host-iface=&lt;iface&gt;

Specify the network interface to use for the connection.

-I &lt;hostid&gt;, --hostid=&lt;hostid&gt;

Specify the host UUID.

-q &lt;hostnqn&gt;, --hostnqn=&lt;hostnqn&gt;

Override the default host NQN.

-w &lt;traddr&gt;, --host-traddr=&lt;traddr&gt;

Specify the source address on the host side of the connection.

-k &lt;#&gt;, --keep-alive-tmo=&lt;#&gt;

Set the keep-alive timeout in seconds.

--keyring=&lt;keyring&gt;

Keyring to use for TLS key lookup.

-n &lt;subnqn&gt;, --nqn=&lt;subnqn&gt;

Specify the NVMe subsystem NQN to connect to.

-i &lt;#&gt;, --nr-io-queues=&lt;#&gt;

Number of I/O queues to create.

-P &lt;#&gt;, --nr-poll-queues=&lt;#&gt;

Number of polling queues to create.

-W &lt;#&gt;, --nr-write-queues=&lt;#&gt;

Number of write queues to create.

-Q &lt;#&gt;, --queue-size=&lt;#&gt;

Queue depth for I/O queues.

-l &lt;#&gt;, --ctrl-loss-tmo=&lt;#&gt;

Maximum time in seconds to retry reconnect attempts after controller loss.

-s &lt;trsvcid&gt;, --trsvcid=&lt;trsvcid&gt;

Transport service identifier (e.g. TCP/rdma port). Default is 4420 for RDMA.

-T &lt;#&gt;, --tos=&lt;#&gt;

Type of service value for the connection (TCP).

-t &lt;trtype&gt;, --transport=&lt;trtype&gt;

Specify the transport type. Supported values include:

\+

Value Description rdma RDMA (RoCE, iWARP, InfiniBand) tcp TCP/IP fc Fibre Channel (**experimental**) loop Local loopback transport

--tls

Enable TLS encryption (TCP).

--tls-key=&lt;tls-key&gt;

TLS key for the connection. It is recommended to preload keys into the system keyring instead of passing them via the command line.

--tls-key-identity=&lt;identity&gt;

Identity associated with the TLS key.

# [GLOBAL OPTIONS](#GLOBAL_OPTIONS)

The following options are defined at the top-level nvme command and are available to this subcommand:

--dry-run

Print the command that would be executed, but do not actually execute it.

--no-ioctl-probing

Disable probing for 64-bit IOCTL support.

--no-retries

Disable retry logic on transient errors.

-o &lt;fmt&gt;, --output-format=&lt;fmt&gt;

Set the reporting format to *normal*, *tabular, 'json*, or *binary*. Only one output format may be used at a time.

--output-format-version=&lt;version&gt;

Select the output format version. Version *1* uses the original field naming, while version *2* (default) provides more consistent and script-friendly field names. Other versions are rejected.

--quiet

Suppress informational messages. Errors are still reported, and --quiet cancels any --verbose for the library log level.

--set-options=&lt;key=value&gt;\[,&lt;key=value&gt;...]

Set libnvme library options for this invocation. Supported keys are *force-4k*, *mi-probe-enabled*, *test-base-dir* and *test-sysfs-dir*.

--timeout=&lt;ms&gt;

Set the timeout for the command in milliseconds. *infinite* or *-1* waits without a time limit (0xffffffff).

-v, --verbose

Increase the level of detail in the output. May be specified multiple times to further increase verbosity.

These options can also be set as machine-wide defaults in [nvme-cli.conf(5)](/man/os/nvme-cli/nvme-cli.conf.5). A command-line flag always overrides the file.

# [EXAMPLES](#EXAMPLES)

•Connect to all records returned by the Discover Controller with IP4 address 192.168.1.3 for all resources allocated for NVMe Host name host1-rogue-nqn on the RDMA network. Port 4420 is used by default:

```
# nvme connect-all --transport=rdma --traddr=192.168.1.3 \
--hostnqn=host1-rogue-nqn
```

•Issue a *nvme connect-all* command using the default system defined NBFT tables:

```
# nvme connect-all --nbft
```

•Issue a *nvme connect-all* command with a user-defined path for the NBFT table:

```
# nvme connet-all --nbft-path=/sys/firmware/acpi/tables/NBFT1
```

•Issue a *nvme connect-all* command using a /usr/local/etc/nvme/discovery.conf file:

```
# Machine default 'nvme discover' commands. Query the
# Discovery Controller's two ports (some resources may only
# be accessible on a single port). Note an official
# nqn (Host) name defined in the NVMe specification is being used
# in this example.
-t rdma -a 192.168.69.33 -s 4420 -q nqn.2014-08.com.example:nvme:nvm-subsystem-sn-d78432
-t rdma -a 192.168.1.4   -s 4420 -q nqn.2014-08.com.example:nvme:nvm-subsystem-sn-d78432
At the prompt type "nvme connect-all".
```

# [SEE ALSO](#SEE_ALSO)

[nvme-discover(1)](/man/os/nvme-cli/nvme-discover.1) [nvme-connect(1)](/man/os/nvme-cli/nvme-connect.1)

# [NVME](#NVME)

Part of the nvme-user suite

10/30/2026 NVMe

---

Document: nvme-connect-all(1) from nvme-cli 3.2-r0 (Chainguard OS)
Source: https://github.com/linux-nvme/nvme-cli
