Skip to content

Commit 209806c

Browse files
stuggiclaude
andcommitted
Document CSI Volume Snapshot requirement for OADP backup/restore
CRITICAL: The staged deployment restore approach requires CSI Volume Snapshots to work correctly. Why CSI snapshots are required: - Staged restore pauses at infrastructure-only (no service pods) - PVCs must be restored with data BEFORE pods start - Filesystem backup (Restic/Kopia) requires pods to mount PVCs during restore, which breaks the staged approach - CSI snapshots restore data at storage layer without pods Changes: 1. docs/dev/backup-restore-storage-volumes.md - Add CSI Volume Snapshot as critical requirement - List supported vs unsupported StorageClasses - Provide VolumeSnapshotClass example for LVM - Update "What OADP Provides" to clarify CSI snapshots - Update backup strategy table 2. docs/dev/README.md - Add CSI Volume Snapshot Support section - Link to storage volume prerequisites - Clarify supported storage types 3. docs/dev/playbooks/backup-openstack-ctlplane.yaml - Change backup spec from filesystem to CSI snapshots: - Remove: defaultVolumesToRestic: true - Add: snapshotVolumes: true - Add: defaultVolumesToFsBackup: false - Update backup header message Supported StorageClasses: - LVM storage (TopoLVM/LVMS) - Ceph RBD - Cloud provider storage (AWS EBS, Azure Disk, GCP PD) NOT Supported: - Local storage (node-local directories) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 14a0122 commit 209806c

3 files changed

Lines changed: 75 additions & 8 deletions

File tree

docs/dev/README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ oc project openstack
4242

4343
See also: [OADP Setup Playbooks](#oadp-setup-playbooks) for automated installation using Ansible.
4444

45+
**IMPORTANT:** OADP backup/restore requires a StorageClass that supports **CSI Volume Snapshots**. See [Storage Volume Prerequisites](#csi-volume-snapshot-support) below.
46+
4547
### Restore Prerequisites
4648

4749
#### Operator Version Matching
@@ -63,6 +65,29 @@ The target cluster must have the same storage classes available as the source cl
6365

6466
See [Storage Class Requirements](backup-restore-ctlplane.md#storage-class-requirements) for detailed procedures.
6567

68+
#### CSI Volume Snapshot Support
69+
70+
**CRITICAL REQUIREMENT**: Both source and target clusters must have a StorageClass that supports **CSI Volume Snapshots**.
71+
72+
**Why this is critical:**
73+
- The staged deployment restore approach requires PVCs to be restored **before** service pods start
74+
- Filesystem backup (Restic/Kopia) requires pods to mount PVCs during restore, which breaks the staged approach
75+
- CSI snapshots restore data at the storage layer without needing pods
76+
77+
**Supported StorageClasses:**
78+
- ✅ LVM storage (TopoLVM/LVMS)
79+
- ✅ Ceph RBD
80+
- ✅ Cloud provider storage (AWS EBS, Azure Disk, GCP PD)
81+
- ❌ Local storage (node-local directories) - **NOT supported**
82+
83+
**Verification:**
84+
```bash
85+
# Check if VolumeSnapshotClass exists
86+
oc get volumesnapshotclass
87+
```
88+
89+
See [Storage Volume Backup Prerequisites](backup-restore-storage-volumes.md#prerequisites) for detailed setup instructions including VolumeSnapshotClass creation.
90+
6691
## Core Backup/Restore Procedures
6792

6893
| Document | Description |

docs/dev/backup-restore-storage-volumes.md

Lines changed: 46 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,15 @@ This guide covers backing up and restoring persistent volumes for OpenStack serv
88

99
### What OADP Provides
1010

11-
-**Automated PVC/PV backups** using Restic for file-level backups
11+
-**Automated PVC/PV backups** using CSI Volume Snapshots (requires CSI-capable StorageClass)
12+
-**Storage-level snapshots** that restore data before pods start (critical for staged deployment)
1213
-**Scheduled backups** (daily, weekly, etc.)
1314
-**Label-based selection** for backup filtering
1415
-**S3-compatible object storage** integration (MinIO, AWS S3, etc.)
1516
-**Retention policies** and automatic cleanup
1617

18+
**Note:** Filesystem backup (Restic/Kopia) is not compatible with the staged deployment restore approach because it requires pods to mount PVCs during restore.
19+
1720
### What OADP Does NOT Handle
1821

1922
OADP complements, but does not replace, other backup methods:
@@ -26,20 +29,57 @@ OADP complements, but does not replace, other backup methods:
2629

2730
| Component | Backup Method | Reason |
2831
|-----------|---------------|--------|
29-
| **MariaDB/Galera** | Dedicated procedure | Ensures transactional consistency |
32+
| **MariaDB/Galera** | Dedicated procedure + OADP (backup PVCs only) | Ensures transactional consistency via dumps; OADP backs up dump files |
3033
| **OVN Databases** | Dedicated procedure | Ensures database consistency |
3134
| **RabbitMQ** | No backup | Ephemeral, recreated on restore |
32-
| **Glance** | **OADP/Restic** | Image storage needs file-level backup |
33-
| **Cinder** | **OADP/Restic** | Volume backend storage (depends on backend) |
34-
| **Swift** | **OADP/Restic** | Object storage (if using PVC backend) |
35-
| **Manila** | **OADP/Restic** | Share storage (depends on backend) |
35+
| **Glance** | **OADP/CSI Snapshots** | Image storage PVCs backed up at storage layer |
36+
| **Cinder** | **OADP/CSI Snapshots** | Volume backend storage PVCs (depends on backend) |
37+
| **Swift** | **OADP/CSI Snapshots** | Object storage PVCs (if using PVC backend) |
38+
| **Manila** | **OADP/CSI Snapshots** | Share storage PVCs (depends on backend) |
3639

3740
## Prerequisites
3841

42+
**CRITICAL REQUIREMENT: CSI Volume Snapshot Support**
43+
44+
The backup/restore procedure with staged deployment requires a StorageClass that supports **CSI Volume Snapshots**. This is because:
45+
- The restore procedure uses infrastructure-only staging (no service pods running)
46+
- PVCs must be restored with data **before** pods start
47+
- Filesystem backup (Restic/Kopia) requires pods to mount PVCs during restore
48+
- CSI snapshots restore data at the storage layer without needing pods
49+
50+
**Supported StorageClasses:**
51+
- ✅ LVM storage (TopoLVM/LVMS) - supports CSI snapshots
52+
- ✅ Ceph RBD - supports CSI snapshots
53+
- ✅ Most cloud provider storage (AWS EBS, Azure Disk, GCP PD) - support CSI snapshots
54+
- ❌ Local storage (node-local directories) - **does NOT support CSI snapshots**
55+
56+
**Required Setup:**
3957
- OADP operator installed and configured (see [setup-oadp-minio.md](setup-oadp-minio.md))
4058
- MinIO or other S3-compatible storage configured as backup location
59+
- **VolumeSnapshotClass configured** for your storage provider (see below)
4160
- PVCs labeled for backup (see labeling section below)
4261

62+
**Verify CSI Snapshot Support:**
63+
64+
```bash
65+
# Check if VolumeSnapshotClass exists
66+
oc get volumesnapshotclass
67+
68+
# For LVM storage (TopoLVM/LVMS), create if missing:
69+
cat <<EOF | oc apply -f -
70+
apiVersion: snapshot.storage.k8s.io/v1
71+
kind: VolumeSnapshotClass
72+
metadata:
73+
name: lvms-vsc
74+
labels:
75+
velero.io/csi-volumesnapshot-class: "true"
76+
driver: topolvm.io
77+
deletionPolicy: Delete
78+
EOF
79+
```
80+
81+
**Note:** If your storage does not support CSI snapshots, you cannot use the staged deployment restore approach. See [backup-restore-ctlplane.md](backup-restore-ctlplane.md) for alternative restore strategies.
82+
4383
## Label Convention
4484

4585
Services that need PVC/PV backup should label their PVCs with:

docs/dev/playbooks/backup-openstack-ctlplane.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,8 @@
512512
- "Step 10: Backup Storage Volumes (OADP)"
513513
- "========================================"
514514
- ""
515-
- "Backing up PVCs with label openstack.org/backup=true"
515+
- "Backing up PVCs with label openstack.org/backup=true using CSI Volume Snapshots"
516+
- "REQUIRES: StorageClass with CSI snapshot support (LVM, Ceph RBD, cloud provider storage)"
516517
- "See: docs/dev/backup-restore-storage-volumes.md"
517518
when: not skip_pvc_backup
518519

@@ -561,7 +562,8 @@
561562
labelSelector:
562563
matchLabels:
563564
openstack.org/backup: "true"
564-
defaultVolumesToRestic: true
565+
snapshotVolumes: true
566+
defaultVolumesToFsBackup: false
565567
storageLocation: velero-1
566568
ttl: 720h
567569
EOF

0 commit comments

Comments
 (0)