Storage · Linux Storage
LVM
Cheat sheet · https://pcornel.dk/topic.php?topic=4001
Answer
LVM (Logical Volume Manager) groups physical volumes into volume groups and carves them into logical volumes that can be resized, snapshotted or moved online, managed with pvs, vgs and lvs.
Remember
- PV → VG → LV layering.
- lvextend -r grows the file system too.
- Thin pools can overfill; monitor data and metadata.
First checks
pvs; vgs; lvs— LVM overviewlvs -a -o +devices— mappinglvm fullreport— complete state
Verify in this order
PV → VG → LV → filesystem
Where it usually breaks
First mismatch in provider/pool → virtual/logical disk → host/guest mapping → partition/filesystem → mount/drive → workload; preserve identity/pre-state before mutation.
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=4001