1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/virt-deleting-vm-snapshot-cli.adoc
2025-11-18 16:29:25 +01:00

35 lines
827 B
Plaintext

// Module included in the following assemblies:
//
// * virt/backup_restore/virt-managing-vm-snapshots.adoc
:_mod-docs-content-type: PROCEDURE
[id="virt-deleting-vm-snapshot-cli_{context}"]
= Deleting a virtual machine snapshot in the CLI
[role="_abstract"]
You can delete an existing virtual machine (VM) snapshot by deleting the appropriate `VirtualMachineSnapshot` object.
.Prerequisites
* Install the OpenShift CLI (`oc`).
.Procedure
* Delete the `VirtualMachineSnapshot` object:
+
[source,terminal]
----
$ oc delete vmsnapshot <snapshot_name>
----
+
The snapshot controller deletes the `VirtualMachineSnapshot` along with the associated `VirtualMachineSnapshotContent` object.
.Verification
* Verify that the snapshot is deleted and no longer attached to this VM:
+
[source,terminal]
----
$ oc get vmsnapshot
----