brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: findmnt --verify checks fstab before a reboot can break the disk mounts

Disk
~/tips/tip-disk-findmnt-verify-fstab

sudo findmnt --verify --verbose

Checks fstab for typos and missing devices without mounting anything.

A typo in fstab is found at boot time, which is the worst moment. I check the file right after I edit it.

sudo findmnt --verify --verbose

--verify parses /etc/fstab and reports unknown filesystem types, missing mount points and UUIDs that point to no existing device. It does not mount anything. A warning is not always an error, for example a disk that is unplugged on purpose but marked nofail. Follow it with sudo mount -a to prove that every line really mounts. It is part of util-linux, so it is already on Debian and Ubuntu.

Further reading: findmnt manual page

More Disk tips sudo e2freefrag /dev/sdb1 sudo smartctl -a --json /dev/sda | jq '.smart_status.passed' lsscsi -s udisksctl power-off -b /dev/sdX du -sh — .[!.]* * 2>/dev/null | sort -h All Disk tips (44) All topics

Link