RAID and snapshots
Quick answer
RAID can improve availability after certain disk failures. Snapshots preserve a point-in-time view. Neither alone is an independent backup.
Prepare the practice environment
Run python3 lab-fixtures/backup/setup.py from the extracted root as an ordinary user. Enter the printed fresh private path and check pwd. Use fresh fixtures, Bash with set -e -o pipefail, LC_ALL=C and umask 077. Only disposable regular files may be written. Optional examples require an authorized snapshot VM. Never substitute real devices, mount remote shares or change storage configuration. Review the lab guide.
How it works
RAID 0 stripes data without redundancy; RAID 1 mirrors data; RAID 5 uses distributed parity and tolerates one member failure in a healthy array. Rebuilds can fail and redundancy is not protection against deletion or ransomware. A classic LVM snapshot tracks changed blocks and may become invalid if its allocated space fills; thin snapshots depend on pool capacity. A filesystem snapshot may be crash-consistent rather than application-consistent. Quiesce applications or use their backup APIs. The fixture models two members and an independent file copy; it is not an actual RAID array.
Imagine both mirrored members contain a file that is accidentally overwritten. A healthy mirror can preserve availability but normally propagates the overwrite to both members. A retained version from before the mistake can help only if it remains accessible and valid. A snapshot on the same storage shares some failure risks with the source; keep independent recovery copies and verify restores.
Try the examples
awk '$2=="failed" {n++} END {print n+0}' raid.txtOne modeled member has failed. A healthy two-member mirror can normally survive this, but inspect the real array and backup.
Expected stdout:
1cp data/report.txt working.txtcp working.txt snapshot-copy.txtprintf 'changed\n' > working.txtcmp data/report.txt snapshot-copy.txt && printf 'copy verified\n'The ordinary copy demonstrates independent content, not block-level snapshot behavior.
Expected stdout:
copy verifiedVM-only inspection; the scan summarizes configured active arrays, not a full health guarantee.
Manual example; not executed locally. Follow its stated environment restrictions.
Common mistakes
Do not treat mirroring or a snapshot on the same storage as disaster recovery. Check snapshot capacity and preserve independent copies.
Practice
Compare a disk failure, accidental deletion and total site loss. State which of RAID, a local snapshot and an offsite backup can help each scenario.
Related references
Study: mdadm. These are reference names, not deployed links.
Check Your Understanding
Solidify your learning with the interactive assessment directly below this lesson.
Concept Quiz & Questions
RAID and snapshots — Knowledge Check
Apply advanced storage and backup concepts to synthetic fixtures and VM-only scenarios.
Which level has no redundancy?
Why is RAID not a backup?
What may invalidate a classic snapshot?
What helps ensure database-consistent backups?