Forrest logo
back to the mkfs tool

mkfs:tldr:3d74d

mkfs: Build a filesystem of a specified type.
$ mkfs -t ${ext4} ${path-to-partition}
try on your machine

The command "mkfs" is used to create a file system on a storage device or partition. It stands for "make file system." In this case, the "-t" option specifies the type of file system to be created.

The variable "${ext4}" is likely an environment variable that holds the value "ext4," which indicates that an Ext4 file system should be created. Ext4 is a popular file system used by many Linux distributions.

The variable "${path-to-partition}" represents the path to the partition on which the file system will be created. For example, it could be something like "/dev/sdb1" or "/dev/nvme0n1p2," depending on the device and partition you want to format.

Overall, this command is used to create an Ext4 file system on a specific partition by specifying the type of file system and the path to the partition.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the mkfs tool