LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

qm-destroy

Permanently remove a Proxmox virtual machine

TLDR

Destroy a specific virtual machine
$ qm destroy 100
copy
Destroy and remove all unreferenced disks from enabled storages
$ qm destroy 100 --destroy-unreferenced-disks
copy
Destroy and purge from backup, replication jobs, and HA configuration
$ qm destroy 100 --purge
copy
Destroy with purge and remove unreferenced disks
$ qm destroy 100 --purge --destroy-unreferenced-disks
copy
Force destroy ignoring locks (root only)
$ sudo qm destroy 100 --skiplock
copy

SYNOPSIS

qm destroy vmid [OPTIONS]

DESCRIPTION

qm destroy permanently removes a virtual machine and all associated volumes from Proxmox VE. The operation also removes any VM-specific permissions and firewall rules.The --purge option removes the VMID from backup jobs, replication jobs, and high availability configuration. The --destroy-unreferenced-disks option removes disks that are not referenced in the VM configuration but have a matching VMID across all enabled storages. The --skiplock option bypasses safety locks but requires root privileges.

PARAMETERS

--destroy-unreferenced-disks boolean

If set, additionally destroy all disks not referenced in the config but with a matching VMID from all enabled storages. Default: 0.
--purge boolean
Remove VMID from configurations, like backup and replication jobs and HA.
--skiplock boolean
Ignore locks. Only root is allowed to use this option.

CAVEATS

Destruction is permanent and cannot be undone. Ensure backups exist before destroying important VMs. The VMID must be in the range 100-999999999.

HISTORY

Part of Proxmox VE QEMU/KVM management tools for virtual machine administration.

SEE ALSO

qm(1), qm-create(1), qm-clone(1), qm-stop(1), qm-shutdown(1)

Copied to clipboard
Kai