Skip to main content

Choosing a technology for a workload

Choosing a technology for a workload​

The engine is only half the decision. What makes a copy restorable depends on how the data is quiesced when the copy is taken — which is why a database rarely wants the same treatment as a stateless web server.

Snapshot and Backup Technologies by Use Case​

TechnologyVMs (Basic)VMs with Consistency (qemu-guest-agent)DB (Non-Prod)DB (Low Transactions)DB (High Transactions)Kubernetes Persistent Volumes
VM Snapshot (as-is)✅ (Crash-consistent)❌ (Use qemu-guest-agent instead)✅ (Crash-consistent, risk of corruption)❌ (Risk of data loss)❌ (High risk of data loss)❌ (Not recommended)
VM Snapshot + qemu-guest-agent✅ (Filesystem consistent)✅ (Filesystem consistent)✅ (Filesystem consistent, but DB may still have logical inconsistencies)✅ (Improved consistency)❌ (Not sufficient for high transactions)❌ (Not applicable)
VM Snapshot + qemu-guest-agent + Custom Hooks❌ (Overkill for basic VMs)✅ (DB-consistent if hooks are configured)✅ (DB-consistent)✅ (DB-consistent)✅ (DB-consistent, but requires careful hook setup)❌ (Not applicable)
Native DB Tools (e.g., pg_dump, mysqldump)❌ (Not for VM recovery)❌ (Not for VM recovery)✅ (Granular recovery)✅ (Granular recovery)✅ (Best for granular recovery)❌ (Not for K8s volumes)
Velero + CSI (e.g., csi-cinder)❌ (Not for VMs)❌ (Not for VMs)❌ (Not for DBs directly)❌ (Not for DBs directly)❌ (Not for DBs directly)✅ (Cluster-consistent, includes persistent volumes)

Caveats by Technology​

  • VM Snapshot (as-is):

    • Caveat: Crash-consistent only. Risk of data corruption if the VM was writing data during the snapshot.
  • VM Snapshot + qemu-guest-agent:

    • Caveat: Filesystem consistent, but DBs may still have logical inconsistencies (e.g., uncommitted transactions).
  • VM Snapshot + qemu-guest-agent + Custom Hooks:

    • Caveat: Requires scripting and manual configuration in Trilio. Hooks must be tested to ensure they work as expected.
  • Native DB Tools:

    • Caveat: Does not recover the entire VM or OS. Only useful for DB-level recovery.
  • Velero + CSI:

    • Caveat: Requires Velero setup and CSI driver configuration. Does not replace DB-native tools for granular DB recovery.

Recommendations by Use Case​

  • VMs (Basic): Use VM Snapshot (as-is) or VM Snapshot + qemu-guest-agent for filesystem consistency.
  • VMs with Consistency: Use VM Snapshot + qemu-guest-agent.
  • DB (Non-Prod): Use VM Snapshot + qemu-guest-agent or Native DB Tools for granular recovery.
  • DB (Low Transactions): Use VM Snapshot + qemu-guest-agent + Custom Hooks or Native DB Tools.
  • DB (High Transactions): Use Native DB Tools for granular recovery and VM Snapshot + qemu-guest-agent + Custom Hooks for full VM recovery.
  • Kubernetes Persistent Volumes: Use Velero + CSI for cluster-level recovery.

Usage​

Configuring backup targets, creating and scheduling workloads, and restoring data with each engine.