mkfs Linux Command
Creates a filesystem (formats) on a disk partition.
What does mkfs do?
Creates a filesystem (formats) on a disk partition.
Syntax
mkfs -t type devicePractical example
sudo mkfs -t ext4 /dev/sdb1Related Disk Commands
umountUnmounts a filesystem (detaches a mounted device from the directory tree).
fsckChecks and optionally repairs a filesystem for errors.
mountMounts a filesystem (attaches a device to the directory tree).
ddCopies and converts raw data at the block level (disk cloning, bootable USB creation).
fdiskManipulates disk partition table (create, delete, resize partitions).
blkidDisplays block device attributes including UUID and filesystem type.