-
Epic
-
Resolution: Unresolved
-
Critical
-
None
-
None
-
Support for Storage Agnostic qcow2 Incremental Backup
-
Product / Portfolio Work
-
3
-
False
-
-
False
-
Not Selected
-
To Do
-
ToDo
-
Very Likely
-
0
-
None
-
Unset
-
Unknown
Storage Agnostic qcow2 Incremental Backup Support
KubeVirt Enhancement Proposal: Incremental Backup
Design Document: Virt Incremental qcow2 Datamover
Overview
This epic implements storage agnostic qcow2 incremental backup support for virtual machines in OADP/Velero environments. The feature introduces a lightweight alternative to traditional VolumeSnapshot-based backups by leveraging libvirt tools for incremental qcow2 backups, significantly improving backup performance and enabling more frequent backup operations.
Background and Motivation
Taking a VolumeSnapshot and using kopia to process the entire volume for incremental changes is a heavyweight process. Creating an incremental qcow2 backup for the same volume is generally much more lightweight. This enhancement aims to:
- Improve volume backup performance in KubeVirt environments
- Enable more frequent backups through reduced resource overhead
- Leverage existing libvirt tooling for VM-specific backup operations
- Integrate seamlessly with existing Velero backup/restore processes
Architecture Overview
Virt Backup Controller
- New controller component for coordinating libvirt backup/restore operations
- Integration with Velero via existing infrastructure (BackupItemActions, RestoreItemActions)
- Support for DataUpload/DataDownload CRs with custom DataMover specification
Integration Points
- Minimal changes to Velero core (leverages existing extensibility)
- Uses Velero's volume policy model with new "virt" action
- Coordinates with existing OADP infrastructure
Key Features
Incremental Backup Support
- First backup for a volume is full backup
- Subsequent backups are incremental, capturing only changes
- Significant performance improvement over traditional CSI snapshot methods
- Support for more frequent backup schedules
Storage Agnostic Design
- Works independently of underlying storage provider
- Leverages qcow2 format for efficient incremental operations
- Compatible with various backup storage locations (BSL)
VM-Aware Operations
- Integration with KubeVirt VirtualMachineInstance resources
- Support for QEMU backup capabilities (CBT - Changed Block Tracking)
- Automatic detection of backup-enabled disks
Technical Implementation
Upstream Velero Changes
- Update volume policy model to allow unrecognized actions (treat as "skip")
- Add SnapshotType support in DataUpload/DataDownload operations
- Enhance restore actions for virt datamover compatibility
Plugin Development
_ _VirtualMachineInstance BackupItemAction (BIA) Plugin:*
- Check for QEMU backup enablement (Spec.Domain.Devices.Disk[i].CBT = true)
- Validate volume policy configuration ("virt" action)
- Create temporary PVC for qcow2 image storage
- Coordinate with Virt Backup Controller
_ _RestoreItemAction (RIA) Plugin:*
- Handle restoration of qcow2-backed volumes
- Coordinate with controller for libvirt restore operations
- Manage temporary storage during restore process
Controller Implementation
_ _Virt Backup Controller:*
- Watch for DataUpload CRs with virt datamover specification
- Execute libvirt backup operations using appropriate tools
- Manage backup chain and incremental relationships
- Handle backup storage and retrieval operations
Volume Policy Configuration
Policy Requirements
- VM volumes must be configured with "virt" policy action
- No mixing of policy types within single VM (all "virt" or "skip")
- Automatic fallback for unsupported configurations
Prerequisites and Requirements
VM Configuration
- QEMU backup must be enabled on VM disks (CBT = true)
- VMs must be running KubeVirt with appropriate capabilities
- Sufficient temporary storage for qcow2 image processing
Infrastructure Requirements
- Virt Backup Controller deployment
- Access to libvirt tools and capabilities
- Network connectivity for backup storage operations
Use Cases
Primary Use Cases
- High-frequency backups for development environments
- Efficient backup of large VM workloads
- Storage-independent backup solutions
- Reduced backup window requirements
User Workflow
1. Configure VM with QEMU backup enabled (CBT = true)
2. Set volume policy to "virt" for target volumes
3. Create OADP backup with virt-enabled volumes
4. Controller performs incremental qcow2 backup
5. Restore operations use libvirt tooling for recovery
Benefits and Advantages
Performance Improvements
- Significantly faster than CSI snapshot + kopia processing
- Reduced resource consumption during backup operations
- Minimal impact on running VM performance
- Efficient incremental change detection
Operational Benefits
- More frequent backup schedules possible
- Storage provider independence
- Leverages proven libvirt backup technology
- Seamless integration with existing OADP workflows
Limitations and Considerations
Current Limitations
- Requires QEMU backup capability (CBT support)
- VM-specific solution (not applicable to non-VM workloads)
- Additional controller component required
- Temporary storage requirements for qcow2 processing
Future Enhancements
- Deep integration with Velero data mover pluggability
- Enhanced monitoring and observability
- Support for additional VM backup formats
- Performance optimization and tuning
Testing Strategy
- Unit tests for plugin components
- Integration tests with KubeVirt environments
- End-to-end backup and restore validation
- Performance benchmarking against traditional methods
- Multi-VM scenario testing
- Failure recovery and error handling validation
Target Release
- Implementation target: OADP 1.6.0
- Technology Preview phase initially
- Full support after validation and testing
Success Criteria
- Successful incremental backup of KubeVirt VMs
- Performance improvement over traditional CSI snapshots
- Seamless integration with existing OADP workflows
- Reliable restore operations
- Comprehensive documentation and user guidance