LinuxCommandLibrary

qm-nbdstop

Stop NBD export of a QEMU VM disk

TLDR

Stop embedded nbd server

$ qm [[n|nbdstop]] [VM_ID]
copy

SYNOPSIS

qm-nbdstop <IP_ADDRESS> <PORT>

PARAMETERS

IP_ADDRESS
    The IP address (or hostname) where the NBD server to be stopped is listening. This must match the address used when the NBD server was started.

PORT
    The TCP port number where the NBD server to be stopped is listening. This must match the port used when the NBD server was started.

DESCRIPTION

The qm-nbdstop command is part of the Proxmox Virtual Environment (PVE) suite of tools, specifically designed to manage Network Block Device (NBD) servers. Its primary function is to cleanly shut down an NBD server instance that was previously started, typically by the qm-nbdstart command.

NBD allows a block device (like a virtual machine disk image) to be exported over a network, making it accessible as a local block device on a client machine. In Proxmox, this capability is crucial for various advanced operations such as live storage migration, performing online backups of running virtual machines, or mounting a VM's disk image for external manipulation without needing to power down the VM.

When qm-nbdstart exports a VM disk on a specific IP address and port, qm-nbdstop is then used to terminate that export, releasing the associated resources and ensuring data integrity. It's essential for maintaining a clean and controlled environment when leveraging NBD for VM disk access.

CAVEATS

  • The qm-nbdstop command relies on the NBD server process being responsive and accessible at the specified IP and port.
  • It only stops the NBD server process; it does not unmount or detach the NBD device on any client systems that might be connected. Clients must unmount or detach their NBD devices independently.
  • If the NBD server process is unresponsive or has crashed, qm-nbdstop may fail, requiring manual intervention (e.g., using `kill` to terminate the process).
  • Proper permissions are required to terminate the NBD server process, typically root privileges.

HISTORY

The `qm-nbdstart` and `qm-nbdstop` commands are integral parts of the Proxmox Virtual Environment (PVE) management toolset. Their development is closely tied to PVE's evolution, especially its focus on advanced storage management and live migration capabilities. These commands serve as high-level wrappers or direct invocations of underlying NBD utilities (like `qemu-nbd`), providing a user-friendly interface for Proxmox administrators. They were introduced to facilitate operations like online VM backups and seamless storage migrations, becoming a standard part of the PVE ecosystem since the introduction of robust NBD support within Proxmox VE.

SEE ALSO

qm-nbdstart(8), qemu-nbd(8), nbd-server(8), qm(1)

Copied to clipboard