Use it when the disk or LV grew but df still shows the old size.
Resize Filesystem
Resizing a filesystem changes its size to match its block device after the device (partition or LV) changed: resize2fs for ext4, xfs_growfs for XFS, btrfs filesystem resize for Btrfs.
1. lsblk — device size grew?
2. df -h — filesystem still old size?
3. ext4: resize2fs /dev/<dev>; XFS: xfs_growfs <mount>.
4. Partition first if needed: growpart.
5. df -h again.
device grown → filesystem grown to fill it (or shrunk before the device)
For LVM → Resize Filesystem, continue with the first unproven Topic check: Capture LV size, filesystem type/size, mountpoint and workload path. If that boundary is healthy, advance to the adjacent check: Choose direction-specific order based on filesystem capabilities. Preserve the same host/time/identity scope and rerun the original workload before accepting recovery.
Continue only after interpreting the current observation.Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
Verification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Operational evidence path Verify boundary
current LV + filesystem sizes → filesystem capability decision → ordered lower/upper resize → device reread → filesystem metadata update → mount-visible capacity → workload
Healthy evidence: resize order matches filesystem capabilities, LV and filesystem sizes agree afterward, mount-visible capacity is expected and workload I/O succeeds.
Step 2 Verification and output interpretation Verify boundary
Existing fast checks for this Topic. - Capture LV size, filesystem type/size, mountpoint and workload path.
- Choose direction-specific order based on filesystem capabilities.
- Verify each boundary separately: LV/device size, filesystem size, mount-visible capacity.
- Run filesystem integrity/health and workload acceptance after the resize.
Verification chain. current LV + filesystem sizes → filesystem capability decision → ordered lower/upper resize → device reread → filesystem metadata update → mount-visible capacity → workload
Step 3 Commands Verify boundary
resize2fs /dev/vg0/data # ext4
xfs_growfs /data # XFS (mounted)
Step 4 Failure modes and next checks Narrow the fault
Suspicious evidence: upper/lower sizes diverge, unsupported shrink is attempted, stale mount/device state is read, or the wrong filesystem/mount path is validated.
Step 5 Common mistakes Narrow the fault
- Running
xfs_growfson the device instead of the mount point on old versions.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
Order: grow the device first, then the filesystem; shrink the filesystem first, then the device. lvextend -r and growpart + resize do this in the right order.
pvs— physical volumesvgs— volume groups and free spacelvs -a -o +devices— logical volumes and their deviceslsblk— stack view
ReferenceWhat it is1 section · depth on demand
Core model
Identify filesystem type and supported online/offline grow/shrink behavior. For growth, enlarge lower storage before the filesystem. For shrink, shrink/check the filesystem before the LV and only if the filesystem supports it. Integrated LVM resize helpers are convenience orchestration, not a reason to skip before/after evidence.
ReferenceImportant terms & boundaries6 sections · depth on demand
What this shows and what it does not
Filesystem resize evidence shows upper capacity changed only when correlated with LVM device size and final workload path; helper success alone is bounded evidence.
In depth
Growing (and shrinking) a file system on LVM
Resizing storage always has two parts: the block device (partition or LV) and the file system on it. They must be changed in the right order:
- To grow: enlarge the device first, then the file system.
- To shrink: shrink the file system first, then the device.
The resize2fs(8) manual page says this explicitly for ext2/3/4, and adds that resize2fs grows mounted file systems where the kernel supports it, but shrinks only unmounted ones. lvextend(8) can do both steps for growing in one command with -r, which calls fsadm to resize the file system. The xfs_growfs(8) manual page notes that XFS must be mounted to grow, and can't effectively be shrunk.
Growing: one command per case
| Case | Command |
|---|---|
| LVM, any supported file system | lvextend -r -L +20G vg1/app |
| LVM, all remaining free space | lvextend -r -l +100%FREE vg1/app |
| ext4 on a partition | growpart /dev/sda 3 && resize2fs /dev/sda3 |
| XFS on a partition | growpart /dev/sda 3 && xfs_growfs / |
| Root on LVM after a virtual disk grew | growpart, pvresize, lvextend -r |
Shrinking
| File system | Possible? |
|---|---|
| ext4 | Yes, unmounted: e2fsck -f, resize2fs <dev> <size>, then lvreduce (or lvreduce -r) |
| XFS | No; copy the data to a new, smaller volume |
| Btrfs | Yes, online (btrfs filesystem resize) |
A full root file system on a VM
host$ df -h /
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg0-root 30G 29G 1.0G 97% /
host$ echo 1 | sudo tee /sys/class/block/sda/device/rescan
host$ sudo growpart /dev/sda 3
CHANGED: partition=3 start=3147776 old: size=... new: size=...
host$ sudo pvresize /dev/sda3
host$ sudo lvextend -r -L +20G vg0/root
Size of logical volume vg0/root changed from 30.00 GiB to 50.00 GiB.
Logical volume vg0/root successfully resized.
meta-data=/dev/mapper/vg0-root isize=512 agcount=4, agsize=1966080 blks
data blocks changed from 7864320 to 13107200
host$ df -h /
/dev/mapper/vg0-root 50G 29G 22G 58% /
Why -r matters
Without -r, lvextend makes the LV larger, but the file system keeps its old size, and df shows no change. That's a frequent "I extended the volume but got no space" situation. Run the file system tool afterwards (xfs_growfs or resize2fs), or use -r in the first place.
Documented example, not captured output.
Known-good, transitional and broken reference
Resize Filesystem — comparative operational reference for LVM → Resize Filesystem. What it does not show: systemd active/running or host-global state alone does not show the workload context is healthy Next check: move one step toward the original workload using Inspect the path and mount in the process namespace, effective UID/GID/ACL/LSM decision, filesystem/inode state and backend errors, then repeat the original file operation.
How it works at runtime
Resize Filesystem is part of LVM → Resize Filesystem. Resize Filesystem within the LVM branch coordinates an LV size change with the filesystem that consumes it, preserving the critical distinction between lower logical-block capacity and upper filesystem capacity.
Topic-specific state model. Resize Filesystem within the LVM branch coordinates an LV size change with the filesystem that consumes it, preserving the critical distinction between lower logical-block capacity and upper filesystem capacity.
Interpretation rule. - LV resize ≠ filesystem resize.
- Filesystem supports online growth ≠ it supports shrink.
- Integrated resize option success ≠ correct mount/workload verified.
- df size change ≠ lower LVM metadata and device mappings are healthy.
Quick reference
Filesystem resize commands by type:
| Filesystem | Grow | Shrink |
|---|---|---|
| ext4 | resize2fs /dev/vg/lv (online) | resize2fs /dev/vg/lv 80G (offline) |
| XFS | xfs_growfs /mountpoint (online) | Not possible |
| Btrfs | btrfs filesystem resize max /mnt | btrfs filesystem resize -10G /mnt (online) |
| swap | swapoff; mkswap; swapon | same |
Order: when growing, grow the block device first, then the filesystem; when shrinking, shrink the filesystem first, then the block device. lvresize -r and fsadm handle both orders automatically.
Limits and how it fails
Primary failure point. Filesystem resize evidence shows upper capacity changed only when correlated with LVM device size and final workload path; helper success alone is bounded evidence.
ReferenceConfiguration & state1 section · depth on demand
Configuration, persistence and lifecycle
Distribution/platform context. Resize Filesystem owns LVM-to-filesystem coordination. ext4/XFS/Btrfs own filesystem-specific support and repair semantics.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in LVM → Resize Filesystem. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://docs.redhat.com/en/documentation/red_hat_enterprise_linux/9/html/configuring_and_managing_logical_volumes/ · confidence 94%What changed and what may be affected
Recent technical edits are separated from ordinary page timestamps. Relationship impact is advisory: it identifies nearby canonical references to review, not automatic breakage.
Terms & aliases
Hover a linked term for a quick definition; click it to open its glossary entry. Aliases are other names that find this Topic in search.
Quick lookup tables
Resize Filesystem operational reference
Topic-specific lookup boundaries, proof limits and next-step Evidence for Resize Filesystem.
| Lookup boundary | Topic-specific reference | Operational use |
|---|---|---|
| Scope / effective state | Resize Filesystem within the LVM branch coordinates an LV size change with the filesystem that consumes it, preserving the critical distinction between lower logical-block capacity and upper filesystem capacity. | Establish exactly what this Topic owns before crossing into another subsystem. |
| Fast verification | Pin host + incident/change time → capture block topology and stable identities → validate partition/device metadata → validate filesystem identity/integrity and effective mount namespace/options → validate PV/VG/LV/device-mapper state where used → make one controlled change at the first failed boundary → re-read effective storage state → repeat original workload I/O/acceptance test. | Use the shortest evidence path first; a fast check is a boundary test, not blanket proof. |
| Verification chain | current LV + filesystem sizes → filesystem capability decision → ordered lower/upper resize → device reread → filesystem metadata update → mount-visible capacity → workload | Trace requested/configured state through effective state to the observed workload result. |
| Failure boundary | Filesystem resize evidence proves upper capacity changed only when correlated with LVM device size and final workload path; helper success alone is bounded evidence. | Stop broad troubleshooting at the first boundary that is not supported by evidence. |
| Positive evidence | Correlated Linux storage evidence can establish this proof path: current LV + filesystem sizes → filesystem capability decision → ordered lower/upper resize → device reread → filesystem metadata update → mount-visible capacity → workload | Use this observation only for the specific claim it actually supports. |
| Evidence limit | It does not independently prove behavior outside the captured device, metadata, mapping, mount or workload scope. Filesystem resize evidence proves upper capacity changed only when correlated with LVM device size and final workload path; helper success alone is bounded evidence. | Do not promote a local success signal into end-to-end or adjacent-dependency proof. |
| Next troubleshooting check | Continue from the first unproven boundary: prove backing identity, then on-device metadata, then filesystem/LVM mapping and effective mount/device state, and finally repeat the original workload I/O before any additional storage change. | Continue to the next unresolved boundary while preserving the original test condition. |
Resize Filesystem · operational reference
Compact Linux state, persistence, verification and boundary reference for fast lookup.
| Reference boundary | Resize Filesystem |
|---|---|
| Topic path | LVM → Resize Filesystem |
| Runtime state | Resize Filesystem within the LVM branch coordinates an LV size change with the filesystem that consumes it, preserving the critical distinction between lower logical-block capacity and upper filesystem capacity. |
| Fast checks | - Capture LV size, filesystem type/size, mountpoint and workload path. - Choose direction-specific order based on filesystem capabilities. - Verify each boundary separately: LV/device size, filesystem size, mount-visible capacity. - Run filesystem integrity/health and workload acceptance after the resize. |
| Verification chain | current LV + filesystem sizes → filesystem capability decision → ordered lower/upper resize → device reread → filesystem metadata update → mount-visible capacity → workload Boundary chain: local authoritative state → adjacent dependency → effective/programmed state → original workload/request → return/regression → explicit Evidence boundary. Boundary chain: local authoritative state → adjacent dependency → effective/programmed state → original workload/request → return path or regression → explicit Evidence boundary. |
| Failure boundary | Filesystem resize evidence proves upper capacity changed only when correlated with LVM device size and final workload path; helper success alone is bounded evidence. Boundary chain: process credentials/namespace → path/mount lookup → DAC/ACL/LSM → filesystem metadata → block/device/backend → completion/read-back. |
| Persistence rule | Prove which configuration source owns the state, then prove that the running consumer loaded or generated the intended state. |