Shrink a logical volume
high risk
lvreduce -r -L <size> <lv>-r shrinks filesystem and LV in the right orderlvcreate -s -n pre_shrink -L 5G <vg>/<lv>Snapshot before shrinkingReduces the size of an LV. The filesystem must be shrunk first.
| Flag | Meaning |
|---|---|
-r | Shrink the filesystem too |
-L | New size |
lvreduce -r -L 20G /dev/vg0/dataShrink to 20G with the filesystem · explain & risk-check →Reference text is hand-written and may be incomplete — check man lvreduce for your version. Test destructive commands on a non-production system first.