“mkfs.ntfs” is a command-line utility that creates a New Technology File System (NTFS) filesystem on a partition or disk. NTFS is a proprietary file system developed by Microsoft that is primarily used by the Windows operating system. The “mkfs.ntfs” command initializes the partition, creates the necessary file and directory structures, and writes the boot sector and other required information to the partition. NTFS offers several advantages over other file systems, including improved security, support for large file sizes and partitions, and more efficient use of disk space. After the process is complete, the partition is ready to be used to store and access files on systems running Windows or other operating systems with NTFS support.
If you encounter the below error while running the command mkfs.ntfs:
mkfs.ntfs: command not found
you may try installing the below package as per your choice of distribution:
Distribution | Command |
---|---|
Debian | apt-get install ntfs-3g |
Ubuntu | apt-get install ntfs-3g |
Alpine | apk add ntfs-3g |
Arch Linux | pacman -S ntfs-3g |
Kali Linux | apt-get install ntfs-3g |
Fedora | dnf install ntfsprogs-2 |
OS X | brew install ntfs-3g |
Raspbian | apt-get install ntfs-3g |
mkfs.ntfs Command Examples
1. Create a NTFS filesystem inside partition 1 on device b (`sdb1`):
# mkfs.ntfs /dev/sdb1
2. Create filesystem with a volume-label:
# mkfs.ntfs -L volume_label /dev/sdb1
3. Create filesystem with specific UUID:
# mkfs.ntfs -U UUID /dev/sdb1