feat(backups): keep a copy of a live Kubernetes cluster's volumes until its restore succeeds

Ouverte
#5,263 0 commentaires 1 réaction 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 3 jours

Personne n'a encore pris cette issue.

Évaluation

Difficulté
5/5
Temps estimé
Plus d'une semaine
Accessibilité débutants
35/100
Type d'issue
Fonctionnalité
Clarté
Plutôt claire
Activité
Active
Stack technique
go, kubernetes

Piste de recherche

Start by reading the live-cluster restore implementation and the restore Job flow introduced for the Kubernetes backup strategy in issue #4931. Check how the existing Velero snapshot class is selected and how PVCs and DataVolumes are deleted, then verify the stated linstor-csi behavior on a live cluster. Done means failed restores retain usable snapshots identified in the RestoreJob message, while successful restores remove them; the payload names no files or tests.

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

Description

triage/needs-triage

A live-cluster restore of the Kubernetes backup strategy (#4931) restores the volumes by deleting the current DataVolumes and PVCs and letting Velero recreate them, because Velero cannot overwrite an existing claim. If the Velero restore fails after the claims are gone, the data exists only in the backup. The etcd half has no such gap: the restore Job saves the current prefix to <dump>.pre-restore before it writes and drops the copy only after a successful restore.

Proposal: before deleting each claim, take a CSI VolumeSnapshot of it with the class Velero already uses for that storage class, wait for it to be ready, and delete the snapshots after a successful restore. On failure, keep them and name them in the RestoreJob's message, so the claim can be recreated from the snapshot under its original pvc-<uid> name. The default of restoring both halves stays as it is.

To check first on a live cluster: whether linstor-csi deletes a volume that still has a snapshot, or keeps the snapshot usable after the source volume is gone; and how long a snapshot of a large, busy volume takes to become ready, since the cluster is stopped while it is taken.

Langage dominant
Go
Étoiles
2.2k
Forks
209
Merge moyen
4 j 14 h
PR mergées (30 j)
140

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de cozystack/cozystack

Toutes les issues de cozystack/cozystack

Issues similaires

Plus d'issues Go

Recevez les nouvelles issues par e-mail

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