File systems and volumes
Mounting, checking and repairing file systems, and opening encrypted volumes, LVM and software RAID.
Everything here starts from Working safely with disks: nothing is mounted, assembled or unlocked automatically, and on a disk that matters you mark it read-only first.
Checking (-n, no changes) is safe. Repairing writes to the file
system; on a disk with data you need, image it first (ddrescue)
and repair the copy.
| Tool | For |
|---|---|
| mount | mounting read-only, without replaying journals |
| ext2/3/4 | e2fsck, tune2fs, debugfs |
| XFS | xfs_repair, xfs_info |
| Btrfs | btrfs check, btrfs restore |
| NTFS | ntfs-3g, ntfsfix, ntfsinfo |
| FAT and exFAT | fsck.vfat, fsck.exfat |
| cryptsetup | LUKS and BitLocker volumes |
| dislocker | BitLocker volumes (alternative) |
| LVM | logical volumes |
| mdadm | Linux software RAID, and Intel RST (IMSM) sets |