Administration

Move VM and Container Disks Between Storage in Proxmox VE

How to move virtual machine and container disks between storage backends in Proxmox VE using qm move_disk, pct move, online migration, and format conversion.

ProxmoxR app icon

Managing Proxmox? Try ProxmoxR

Monitor and control your VMs & containers from your phone.

Try Free

When to Move Disks Between Storage

Moving VM or container disks between storage backends is a common task in Proxmox VE. You might need to migrate disks from local storage to shared storage for live migration support, move from LVM-thin to ZFS for snapshot capabilities, free up space on one storage pool, or change the disk format from raw to qcow2 (or vice versa). Proxmox provides built-in tools to handle this without manual file copying.

Move VM Disks with qm move_disk

The qm move_disk command moves a VM disk from one storage to another:

# Basic syntax:
qm move_disk <vmid> <disk> <storage> [options]

# Move scsi0 of VM 100 from local-lvm to zfs-pool:
qm move_disk 100 scsi0 zfs-pool

# Move with format conversion (e.g., raw to qcow2):
qm move_disk 100 scsi0 local --format qcow2

# Move and delete the source disk after completion:
qm move_disk 100 scsi0 zfs-pool --delete 1

# Move an EFI disk:
qm move_disk 100 efidisk0 zfs-pool

# Move a TPM state disk:
qm move_disk 100 tpmstate0 zfs-pool

The --delete 1 flag removes the source disk after a successful move. Without it, the original disk remains as an unused disk attached to the VM.

Online Disk Move (Live)

Proxmox supports moving disks while the VM is running (online move). This is possible for most storage backends and avoids VM downtime:

# Online move works the same way — just run the command while the VM is running:
qm move_disk 100 scsi0 zfs-pool --delete 1

# Monitor the progress in the task log:
# Web UI: VM > Task History
# Or via command line:
pvesh get /nodes/pve1/tasks --source all --typefilter move | head -20

# Note: Online move is I/O intensive. For large disks, consider
# scheduling during off-peak hours.

Not all combinations support online moves. If an online move is not supported for your storage types, Proxmox will inform you that the VM must be stopped first.

Move Container Volumes with pct move

For LXC containers, use pct move-volume (previously pct move):

# Move the rootfs of container 200 to zfs-pool:
pct move-volume 200 rootfs zfs-pool

# Move a mount point:
pct move-volume 200 mp0 zfs-pool

# Move with delete of source:
pct move-volume 200 rootfs zfs-pool --delete 1

# Note: Container must be stopped for rootfs moves in most cases.
pct shutdown 200
pct move-volume 200 rootfs zfs-pool --delete 1
pct start 200

Format Conversion During Move

Moving disks between storage types may automatically convert the format, or you can specify the target format explicitly:

# Convert raw (LVM) to qcow2 (directory storage):
qm move_disk 100 scsi0 local --format qcow2

# Convert qcow2 to raw (for LVM-thin or ZFS):
qm move_disk 100 scsi0 local-lvm --format raw

# Storage types and their supported formats:
# LVM / LVM-thin: raw only
# ZFS: raw (subvolume) or qcow2 (zvol)
# Directory / NFS: qcow2 or raw
# Ceph RBD: raw only

# Check current disk format:
qm config 100 | grep scsi0
# Example output: scsi0: local-lvm:vm-100-disk-0,size=32G

Detach and Reattach Disks

An alternative approach is to detach a disk from one VM and reattach it to another, or to manually manage unused disks:

# Detach a disk (makes it "unused"):
qm set 100 --delete scsi1
# The disk is now listed as unused0 in the VM config

# View unused disks:
qm config 100 | grep unused

# Reattach an unused disk:
qm set 100 --scsi1 local-lvm:vm-100-disk-1

# Attach an unused disk to a DIFFERENT VM:
# First, note the full volume path from the source VM config
# Then detach from source and attach to target:
qm set 100 --delete unused0
qm set 101 --scsi1 local-lvm:vm-100-disk-1

# Permanently delete an unused disk:
qm set 100 --delete unused0
# Or from the web UI: Hardware > Unused Disk > Remove (with "Purge" checked)

Move All Disks for a VM

To move all disks of a VM to a new storage, iterate through each disk:

#!/bin/bash
# Move all disks of VM 100 to zfs-pool
VMID=100
TARGET_STORAGE="zfs-pool"

for DISK in $(qm config $VMID | grep -E "^(scsi|virtio|ide|sata|efidisk|tpmstate)" | cut -d: -f1); do
    echo "Moving $DISK to $TARGET_STORAGE..."
    qm move_disk $VMID $DISK $TARGET_STORAGE --delete 1
done

Web UI Method

You can also move disks from the Proxmox web UI. Select the VM, go to Hardware, select the disk, and click "Move Disk" in the toolbar. Choose the target storage and format, and optionally check "Delete source" to remove the original disk after the move.

When moving large disks between storage backends, the operation can take a while. ProxmoxR lets you monitor the task progress from your phone, so you do not have to keep a browser tab open waiting for the move to complete.

Summary

Proxmox VE makes it straightforward to move disks between storage backends using qm move_disk for VMs and pct move-volume for containers. Online moves minimize downtime, format conversion happens automatically when needed, and the --delete 1 flag keeps your storage clean by removing source disks after successful moves. Whether you are migrating to faster storage, consolidating storage pools, or preparing for cluster-wide shared storage, these tools handle the process reliably.

Take Proxmox management mobile

All the features discussed in this guide — accessible from your phone with ProxmoxR. Real-time monitoring, power control, firewall management, and more.

ProxmoxR

Manage Proxmox from your phone

Monitor, control, and manage your clusters on the go.

Free 7-day trial · No credit card required