Pcornel
Browse topics
Options
Recent
Favorites
Linux · Technical reference

Resize Filesystem

Direct answer

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.

When to use this

Use it when the disk or LV grew but df still shows the old size.

First 30 seconds

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.

Operational verification

device grown → filesystem grown to fill it (or shrunk before the device)

Evidence · next step

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
Platform / version applicability
linux
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

Platformlinux
Scope / prerequisiteUse it when the disk or LV grew but df still shows the old size.
What next?3 suggested next steps
Evidence1
On this pageJump to a specific section
Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

5 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

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_growfs on the device instead of the mount point on old versions.
Evidence references

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.

observation · 1
Key points

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.

Key checks
  • pvs — physical volumes
  • vgs — volume groups and free space
  • lvs -a -o +devices — logical volumes and their devices
  • lsblk — 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

CaseCommand
LVM, any supported file systemlvextend -r -L +20G vg1/app
LVM, all remaining free spacelvextend -r -l +100%FREE vg1/app
ext4 on a partitiongrowpart /dev/sda 3 && resize2fs /dev/sda3
XFS on a partitiongrowpart /dev/sda 3 && xfs_growfs /
Root on LVM after a virtual disk grewgrowpart, pvresize, lvextend -r

Shrinking

File systemPossible?
ext4Yes, unmounted: e2fsck -f, resize2fs <dev> <size>, then lvreduce (or lvreduce -r)
XFSNo; copy the data to a new, smaller volume
BtrfsYes, 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.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.

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:

FilesystemGrowShrink
ext4resize2fs /dev/vg/lv (online)resize2fs /dev/vg/lv 80G (offline)
XFSxfs_growfs /mountpoint (online)Not possible
Btrfsbtrfs filesystem resize max /mntbtrfs filesystem resize -10G /mnt (online)
swapswapoff; mkswap; swaponsame

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.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.

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
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor doclinux current

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%
Technical changelog & impact

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.

Related reference impactReview these references after material technical changes when their shared boundary is affected.
Terminology layer

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.

Aliases that resolve here
lvm resize filesystemlvresize fsgrow filesystem lvmshrink filesystem lvm
Embedded reference data

Quick lookup tables

Resize Filesystem operational reference

Topic-specific lookup boundaries, proof limits and next-step Evidence for Resize Filesystem.

Lookup boundaryTopic-specific referenceOperational use
Scope / effective stateResize 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 verificationPin 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 chaincurrent LV + filesystem sizes → filesystem capability decision → ordered lower/upper resize → device reread → filesystem metadata update → mount-visible capacity → workloadTrace requested/configured state through effective state to the observed workload result.
Failure boundaryFilesystem 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 evidenceCorrelated 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 → workloadUse this observation only for the specific claim it actually supports.
Evidence limitIt 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 checkContinue 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 boundaryResize Filesystem
Topic pathLVM → Resize Filesystem
Runtime stateResize 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 chaincurrent 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 boundaryFilesystem 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 ruleProve which configuration source owns the state, then prove that the running consumer loaded or generated the intended state.
Confirmation

Confirm action

Continue?