Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Orphaned snapshots remain after deleting volumes in CLVM_NG primary storage

Open
#14,154 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
58/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
java

Research direction

Start by reproducing the listed volume and snapshot workflow on ACS 4.23 with CLVM_NG and trace the volume-deletion path through the database and GUI records. Compare it with the explicit Volume Snapshot deletion path; done means deleting the original volume no longer leaves a snapshot referencing it, while the underlying LVM cleanup remains intact.

Written by the indexing model from the issue text.

Description

bug
problem

Issue: Orphaned snapshots remain after deleting volumes in CLVM_NG primary storage

I'm seeing an issue with CLVM_NG primary storage where snapshots persist for volumes that have already been deleted.

Reproduction steps:

  1. Deploy a VM with a single root volume that has an associated volume snapshot.
  2. Create a new volume from that snapshot.
  3. Detach the root volume from the VM.
  4. Attach the newly created volume to the VM.
  5. Delete the original volume (the one with the associated snapshot).

Observed behavior:
The snapshot remains in the system, still linked to the deleted volume.

Additional observations:

  • When deleting the volume, I can confirm that the LVM logical volumes (LVs) associated with both the root volume and its snapshot are deleted on the KVM hosts. So the underlying storage is cleaned up correctly.
  • However, the snapshot entry is not removed from the database/GUI
  • If I then manually delete the snapshot from the "Volume Snapshot" section, the operation reports success and the snapshot is no longer displayed in the GUI. This suggests the deletion works, but only when triggered explicitly against the snapshot record.

Expected behavior:
Deleting a volume should also remove (or orphan-clean) any snapshots associated with it, or at minimum the snapshot should no longer reference a non-existent volume.

versions

ACS: 4.23
Primary storage: CLVM_NG
Hypervisor: Rhel9 KVM

Dominant language
Java
Stars
3.1k
Forks
1.4k
Avg merge
6d 20h
Merged PRs (30d)
27

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from apache/cloudstack

All issues in apache/cloudstack

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.