Use this when monitoring file system health.
Filesystem Health
Filesystem health monitoring checks free space and inodes, mount status, read-only remounts, journal and checksum errors, and fsck or scrub results, catching corruption and full volumes early.
1. Filesystem health: errors, read-only remounts, inode exhaustion, space.
2. Alert on errors in kernel log.
3. Schedule checks.
4. Monitor mount status.
5. Act before corruption spreads.
filesystem events → log/metrics → alert
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 Common mistakes Narrow the fault
- Forgetting inode exhaustion.
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.
- Watch free space and inodes.
- Read-only remounts signal errors.
- Check scrub and fsck results.
dmesg | grep -i -e 'EXT4-fs error' -e 'XFS.*error' -e remount— errorsfindmnt -o TARGET,OPTIONS | grep -w ro— read-only mountsdf -i— inodes
ReferenceHow it works1 section · depth on demand
Commands
df -hT ; df -i
dmesg -T | grep -iE 'ext4|xfs|btrfs' | tail
findmnt -O ro
ReferenceImportant terms & boundaries3 sections · depth on demand
In depth
File-system health: errors recorded, checks due, space and inodes
A healthy file system has no recorded errors, is mounted the way it should be, and has space and inodes left. Each file system type records errors in a different place.
ext4: the superblock records history
tune2fs(8) documents -l to list superblock values, including error behaviour and reserved blocks, and -e continue|remount-ro|panic for the error behaviour. It also notes that an error makes e2fsck check the file system on the next boot.
# tune2fs -l /dev/sda2 | grep -E 'Filesystem state|Errors behavior|Last checked|Mount count|FS Error count|First error'
Filesystem state: clean
Errors behavior: Continue
Last checked: Mon Oct 12 09:14:22 2026
Mount count: 41
FS Error count: 2
First error time: Thu Nov 19 03:12:10 2026
# tune2fs -e remount-ro /dev/sda2
FS Error count and First error time show that the kernel recorded errors, even if nobody saw them at the time.
Checks for every file system
| Check | Command |
|---|---|
| Space and inodes | df -hT, df -i |
| Mounted read-only unexpectedly | findmnt -O ro |
| Kernel errors | journalctl -k | grep -iE 'EXT4-fs error|XFS.*(error|corrupt)|BTRFS.*error' |
| ext4 error history | tune2fs -l |
| XFS | xfs_repair -n (unmounted) |
| Btrfs | btrfs device stats /mnt, btrfs scrub status /mnt |
Periodic checks
tune2fs -c (mount count) and -i (interval) control forced checks at boot. Mount-count checking is disabled by default. On servers, scheduled offline checks are often replaced by monitoring of error counts plus checks during maintenance windows.
Alert on
- Any increase in ext4
FS Error countor Btrfs device error counters. - Any file system that is read-only when it should be read-write.
- Space or inode usage above your thresholds.
Documented example, not captured output.
How it works
Filesystem health means the filesystem is mounted read-write, has free space and inodes, and the kernel log shows no corruption or I/O errors. Many filesystems remount read-only on errors to protect data.
Reference
Monitor free space and inodes (df -h, df -i), mount state, read-only remounts and file system errors in kernel logs.
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 Storage Monitoring → Filesystem Health. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://sysstat.github.io/ · confidence 94%