sudo mount /dev/sdb1 /mnt/dataMount a block device using filesystem auto-detection.
Mount, unmount, fstab, filesystem check, and repair workflows on Linux.
Mount devices, images, and network filesystems.
sudo mount /dev/sdb1 /mnt/dataMount a block device using filesystem auto-detection.
sudo mount -o ro /dev/sdb1 /mnt/dataUseful for safe inspection or recovery work.
sudo mount UUID=1234-ABCD /mnt/dataUse a stable identifier instead of a device name.
sudo mount --bind /srv/data /mnt/dataExpose the same directory tree at another path.
sudo mount -o remount,rw /mnt/dataChange mount options for a mounted filesystem.
sudo umount /mnt/dataDetach a mounted filesystem.
sudo umount -l /mnt/dataDetach the mount now and clean up after current users release it.
sudo fuser -vm /mnt/dataHelpful before an unmount that fails with target is busy.
sudo lsof +f -- /mnt/dataFind which processes still hold files on a mounted filesystem.
findmnt -T /mnt/dataShow which filesystem backs a path and how it is mounted.
sudo mount -o loop image.iso /mnt/isoLoop-mount a disk image file.
sudo losetup -fP disk.imgMap a disk image file to the next free loop device.
losetup -aShow loop device mappings.
sudo losetup -d /dev/loop0Disconnect a loop device from its image file.
Persistent mount configuration and boot-time validation.
sudoedit /etc/fstabConfigure persistent mounts, swap, and mount options.
lsblk -fCollect UUIDs and labels for robust /etc/fstab entries.
sudo mount -aValidate /etc/fstab without rebooting.
sudo systemctl daemon-reloadUseful when fstab is consumed into mount units.
systemctl list-units --type=mountSee active mount units managed by systemd.
findmnt --fstabRender how the system interprets /etc/fstab.
sudo systemd-analyze verify /etc/fstabCatch syntax and boot-time mounting issues early.
systemctl status mnt-data.mountInspect mount unit logs and status from systemd.
journalctl -b | grep -i mountReview boot logs when a filesystem did not mount.
Convert a path into the corresponding systemd mount unit name.
systemd-escape -p --suffix=mount /mnt/dataConvert a path into the corresponding systemd mount unit name.
Filesystem consistency checks and repair utilities.
sudo fsck /dev/sdb1Dispatch to the correct fsck helper based on filesystem type.
sudo e2fsck -f /dev/sdb1Run a full ext filesystem check even if marked clean.
sudo e2fsck -y /dev/sdb1Automatically answer yes to filesystem repairs.
sudo xfs_repair /dev/sdb1XFS consistency repair tool.
sudo badblocks -sv /dev/sdbPerform a read-only bad-block scan.
sudo badblocks -wsv /dev/sdbUse only on disks you can erase completely.
sudo smartctl -H /dev/sdaQuick disk health check for SMART-capable devices.
sudo smartctl -a /dev/sdaInspect temperatures, reallocated sectors, and error logs.
sudo smartctl -t short /dev/sdaSchedule a quick device self-test.
sudo smartctl -l selftest /dev/sdaReview completed SMART test results.
sudo nvme listInventory NVMe namespaces and firmware details.
sudo nvme smart-log /dev/nvme0Inspect NVMe wear, temperature, and media error counters.