Search the docs

Admin CLI Workflow to Connect NVMe-oF Enclosures

Connect an NVMe-oF enclosure to a DSX node by using the Admin CLI on the Anvil, the Hammerspace metadata and management node.

  1. Find the name of the DSX node that will own the enclosure:

    Command:

    node-list

    In the output, the DSX nodes show Product node type: DSX.

  2. Read the DSX node’s host NQN, and add it to the array’s host access configuration so that the array presents the intended namespaces to that node. The host NQN identifies the DSX node to the array. It is not a password.

    Command:

    node-list --name <dsx-node-name>

    The host NQN is on the line NVMe-oF host NQN:. In the Management GUI, it is the Host NQN field on the NVMe-oF Config tab that opens when you edit the DSX node on the Storage Systems tab of the Infrastructure page.

    Expected output (trimmed):

    Name:                          dsx1.example.com
    Type:                          Hammerspace
    Product node type:             DSX
    Internal ID:                   1073741839
    ID:                            7887b279-adb3-57d2-a8ca-341eca2c5ca1
    HW state:                      OK
    Node state:                    MANAGED
    Node mode:                     ONLINE
    Management IP:                 192.0.2.21/20
    SW version:                    5.3.1-1209
    S3 auth signing type:          Default
    Vendor:                        VMware, Inc.
    Product name:                  VMware Virtual Platform
    Serial number:                 1ad8256be53e
    Firmware version:              None
    NVMe-oF host NQN:              nqn.2014-08.org.nvmexpress:uuid:0fb02d42-2c53-41ad-3fcf-1ad8256be53e
    Created:                       2026-09-27 18:25:22 UTC
    Modified:                      2026-09-27 23:40:40 UTC
    Components:
                             Type:                    Nic
                             ID:                      892631b6-4d15-577b-96fd-c6bd2bca5b02
                             State:                   OK
    
                             Type:                    Hdd
    <Additional output removed for brevity>
  3. Add the enclosure to the DSX node, with the array’s discovery address as the target. To connect all of the subsystems that the DSX node discovers at the same time, add --connect-all:

    Command:

    nvmeof-config --enclosure-add --dsx-name <dsx-node-name> --target <target-address> --connect-all

    Give every address that the array presents the subsystems on, by repeating --target for each one, when you add the enclosure. Each address becomes a path to each subsystem found there, and multipathing is enabled when a subsystem has more than one. An address that you add to the enclosure later is not connected to subsystems that are already connected; see NVMe-oF Limitations and Operating Guidance. A target is identified by its address; giving the same address again with a different port does not add a target.

    You can use --dsx-id <dsx-node-id> instead of --dsx-name. Leave out --connect-all to add the enclosure without connecting anything yet. The command discovers and connects before it returns, which can take a few minutes; its output shows every subsystem found, with State: CONNECTED on each address that was connected.

    Expected output (two subsystems, two targets, trimmed):

    Type:                    Nvme-of Enclosure
    ID:                      5f2f3932-2c3b-45cd-a27e-f93e8c4f472d
    Name:                    dsx1.example.com::nvmeof-5f2f3932-2c3b-45cd-a27e-f93e8c4f472d
    Node:                    dsx1.example.com
    Node host NQN:           nqn.2014-08.org.nvmexpress:uuid:0fb02d42-2c53-41ad-3fcf-1ad8256be53e
    NVMe-oF config:          Queue depth:             64
                             IO queue pairs:          64
                             I/O policy:              QUEUE_DEPTH
                             Transport:               TCP
                             Target port:             8009
                             Controller loss timeout: -1
    Discovery targets:
                             Address:                 192.0.2.32
                             Port:                    8009
                             Transport:               TCP
    
                             Address:                 192.0.2.31
                             Port:                    8009
                             Transport:               TCP
    Subsystems:
                             Type:                    Nvme-of Subsystem
                             ID:                      7c4b48fa-ce56-5ff2-936f-e68170bb6966
                             Subsystem NQN:           nqn.2026-09.com.example:docs-subsys2
                             Namespaces:
                                                      [Namespace: nvme0n1, Namespace ID: 2, Size: 4.2GB, Sector size: 4096, Model: Docs Lab NVMe Target, Serial: DOCSLAB00000002, Namespace unique ID: bef19a80-60dd-b2bd-30a3-4965b79d3e20, Connected: true]
                                                      [Namespace: nvme0n2, Namespace ID: 1, Size: 4.2GB, Sector size: 4096, Model: Docs Lab NVMe Target, Serial: DOCSLAB00000002, Namespace unique ID: bef19a80-60dd-b2bd-30a3-4965b79d3e20-2, Connected: true]
                             Transport addresses:
                                                      [Address: 192.0.2.32, Port: 8009, Transport: TCP, State: CONNECTED]
                                                      [Address: 192.0.2.31, Port: 8009, Transport: TCP, State: CONNECTED]
    
                             Type:                    Nvme-of Subsystem
                             ID:                      9d588e3f-d951-5d41-b918-d2e557bf8edc
                             Subsystem NQN:           nqn.2026-09.com.example:docs-subsys1
                             Namespaces:
                                                      [Namespace: nvme2n1, Namespace ID: 2, Size: 4.2GB, Sector size: 4096, Model: Docs Lab NVMe Target, Serial: DOCSLAB00000001, Namespace unique ID: c9eedb06-110b-552b-beaa-1cd7e38ae394, Connected: true]
                                                      [Namespace: nvme2n2, Namespace ID: 1, Size: 4.2GB, Sector size: 4096, Model: Docs Lab NVMe Target, Serial: DOCSLAB00000001, Namespace unique ID: c9eedb06-110b-552b-beaa-1cd7e38ae394-2, Connected: true]
                             Transport addresses:
                                                      [Address: 192.0.2.31, Port: 8009, Transport: TCP, State: CONNECTED]
                                                      [Address: 192.0.2.32, Port: 8009, Transport: TCP, State: CONNECTED]
  4. Find the enclosure’s name. An enclosure added from the Admin CLI is named after the DSX node, followed by ::nvmeof- and a unique ID. This is so even if you give --enclosure-name with --enclosure-add: the name you give is ignored.

    Command:

    nvmeof-config --list

    Expected output:

    total 1
    Type:                    Nvme-of Enclosure
    ID:                      5f2f3932-2c3b-45cd-a27e-f93e8c4f472d
    Name:                    dsx1.example.com::nvmeof-5f2f3932-2c3b-45cd-a27e-f93e8c4f472d
    Node:                    dsx1.example.com
    Node host NQN:           nqn.2014-08.org.nvmexpress:uuid:0fb02d42-2c53-41ad-3fcf-1ad8256be53e
  5. If you did not use --connect-all, connect the subsystems you want:

    Command:

    nvmeof-config --enclosure-name <enclosure-name> --connect-nqn <subsystem-nqn>

    Connecting a subsystem that the DSX node did not discover succeeds but connects nothing.

    Run this command after the enclosure has been added. If you give --connect-nqn with --enclosure-add instead, and another enclosure on the DSX node already uses the same target address, the subsystem is discovered but not connected (State: DISCOVERED); run this command to connect it.

  6. Find the device path of each connected namespace. The DSX node’s drive list shows every connected namespace as an Nvme-of Drive with its device path.

    Command:

    drive-list --node-name <dsx-node-name>

    Expected output (trimmed to the NVMe-oF drives):

    total 10
    Type:                    Nvme-of Drive
    ID:                      77620eed-1e30-5c4f-891a-aa4d3dc9718d
    Name:                    /dev/nvme2n2
    State:                   OK
    Capacity:                4.2GB
    Serial number:           77620eed-1e30-5c4f-891a-aa4d3dc9718d
    
    Type:                    Nvme-of Drive
    ID:                      a3874636-842f-5503-8f81-a6bfdb7f6458
    Name:                    /dev/nvme2n1
    State:                   OK
    Capacity:                4.2GB
    Serial number:           a3874636-842f-5503-8f81-a6bfdb7f6458
    
    Type:                    Nvme-of Drive
    ID:                      23770f46-3435-554d-9288-fbfeaeb498c6
    Name:                    /dev/nvme0n1
    State:                   OK
    Capacity:                4.2GB
    Serial number:           23770f46-3435-554d-9288-fbfeaeb498c6
    
    Type:                    Nvme-of Drive
    ID:                      fb91b1e9-8a1b-5eb8-9f44-7c7908708621
    Name:                    /dev/nvme0n2
    State:                   OK
    Capacity:                4.2GB
    Serial number:           fb91b1e9-8a1b-5eb8-9f44-7c7908708621
    
    Type:                    Hdd
    ID:                      2dcbd93d-9bb6-4263-af16-436a3fcc16d7
    Name:                    /dev/dm-2
    State:                   OK
    
    Type:                    Hdd
    ID:                      1c92fad9-da28-4e99-b77f-e8dd28824329
    Name:                    /dev/dm-1
    State:                   OK
    
    Type:                    Hdd
    ID:                      aac8ac10-17fa-4cda-988b-23f65485801f
    Name:                    /dev/dm-0
    State:                   OK
    
    Type:                    Hdd
    ID:                      fd780ea7-e109-4184-947a-bd24b3943920
    Name:                    /dev/sdc
    State:                   OK
    
    Type:                    Hdd
    ID:                      a8fa53db-dd9a-4e9e-9ae4-6125f4e4b530
    Name:                    /dev/sdb
    State:                   OK
    
    Type:                    Hdd
    ID:                      a10ebcbf-2130-44ea-a8d8-c231a801a6bb
    Name:                    /dev/sda
    State:                   OK

    Read the device path right before you use it. Device paths such as /dev/nvme0n1 are assigned by the DSX node’s kernel and can change when a subsystem is disconnected and reconnected.

  7. Create a logical volume on a namespace, and then add it to Hammerspace as a storage volume. The logical volume’s name is in the output of the first command.

    Command:

    logical-volume-create --node-name <dsx-node-name> --device-path <device-path>

    Expected output:

    Type:                    Logical Volume
    ID:                      2b53f6f1-1d21-49f3-aede-637f8ddd806c
    Name:                    /hsvol2
    Exported path:           /hsvol2
    Addresses:
                             [IP: 192.0.2.21/20, Port: 3049, NetId: tcp, NodeNum: 0]
    Node:                    dsx1.example.com
    Usage:                   DS
    Reserved:                false
    Filesystem type:         XFS
    Capacity:                [Total: 4.2GB]
    Hardware:
                             [Type: Nvme-of Drive, ID: 77620eed-1e30-5c4f-891a-aa4d3dc9718d, Name: /dev/nvme2n2, State: OK]
    volume-add --node-name <dsx-node-name> --logical-volume-name <logical-volume-name> --name <volume-name>

    The Management GUI does both in one flow; see Adding an NVMe-oF Enclosure and Subsystems.

  8. To remove the namespaces of a disconnected or removed subsystem from the DSX node’s inventory, refresh the node:

    Command:

    node-refresh --name <dsx-node-name> --reconcile-components