Interview Prep/Linux/Disk space, inodes and filesystems

After a power failure, mounting an XFS volume fails with `mount: /data: wrong fs type, bad option, bad superblock on /dev/sdb1`.

IntermediateTroubleshootingDisk space, inodes and filesystems
Answer

Likely causes → Corrupted log/superblock, wrong device name, or the XFS log needs replay.

Diagnose →

lsblk -f
sudo blkid /dev/sdb1
dmesg -T | tail -30
sudo xfs_repair -n /dev/sdb1       # dry run

Fix → Mount once normally to replay the log; if it fails, run xfs_repair /dev/sdb1. Use xfs_repair -L (zero the log) only as a last resort, as it can lose recent changes. Take a snapshot first.

Prevent → UPS/redundancy, and storage with write cache protection.

All Linux questions Roadmap: Linux

More on Disk space, inodes and filesystems