apache / apache/cloudstack

Cloudstack allows you to create snapshots with the same name for the same volume

Ouverte
#13,051 1 commentaire 0 réactions 0 personnes assignées Voir sur GitHub
component:primary-storage type:bug
Langage dominant
Java
Étoiles
3.1k
Forks
1.4k
Merge moyen
6 j 19 h
PR mergées (30 j)
32

Description

### problem

Bug report:
CloudStack allows creating multiple snapshots of the same volume with identical names.

Image
These snapshots are treated as separate entities in CloudStack, but they reference the same snapshot file on secondary storage.

Image

The snapshot file on secondary storage is overwritten when a snapshot with the same name is created
Image

When one of these snapshots is deleted via CloudStack. The snapshot file is removed from secondary storage. Other snapshot entries remain in CloudStack but no longer have a corresponding file.

Deleted a snapshot in Cloudstack
Image
The first snapshot was deleted from CloudStack. During the deletion process, CloudStack also removed the snapshot file from secondary storage.

Image

However, a second snapshot entry still remains in the database and references a file on secondary storage that no longer exists.

Image

### versions

ACS: 4.20.2.0
Hypervisor: KVM
Primary Storage: Linstor
Secondary Storage: NFS

### The steps to reproduce the bug

1. Create a volume
2. Create snapshot with name for example "test-snapshot"
3. Create another snapshot with the same name "test-snapshot"
4. Verify that both snapshots exist in CloudStack and only one exists on the secondary storage
5. Delete ONE of the snapshots via CloudStack
6. Check secondary storage — snapshot file is removed
7. Check remaining snapshot in CloudStack

### What to do about it?

Prevent creating snapshots with the same name for the same volume. Deleting one breaks the other.

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Commencez par reproduire les étapes indiquées pour deux snapshots portant le même nom sur un volume, puis suivez les chemins de création et de suppression des snapshots concernés. La tâche est terminée lorsque CloudStack rejette le doublon ou, à défaut, conserve la cohérence des entrées de snapshots et des fichiers de secondary-storage lorsqu’un snapshot est supprimé.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
java
Domaine
cloud, infrastructure
Type d'issue
Bug
Difficulté
3/5
Temps estimé
1-2 jours
Activité
Active
Clarté
Plutôt claire
Accessibilité débutants
58/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.