What are LVM snapshots and their limitations?
AdvancedConceptStorage & Memory
Answer
A classic LVM snapshot is a copy-on-write LV: when blocks in the origin change, the old blocks are copied into the snapshot's space first.
sudo lvcreate -s -n lvapp_snap -L 20G /dev/vgdata/lvapp
Limitations: every write to the origin costs an extra copy (performance hit), and if the snapshot's space fills up it becomes invalid. Thin-provisioned LVs give cheaper snapshots. A snapshot is not a backup: it lives on the same disks. For XFS, mount the snapshot with -o nouuid.
More on Storage & Memory
How do you list disks, partitions and filesystems?IntermediateMBR vs GPT partition tables?IntermediateWalk through adding a new disk and mounting it permanently.IntermediateExplain the six fields of an /etc/fstab line.IntermediateWhy use UUIDs and `nofail` in fstab?IntermediateWhat does a bad fstab entry do, and how do you recover?Advanced