Sometimes Linux users need to exchange files with computers running other operating systems, such as Windows or macOS. That’s simple enough with a USB drive—as long as it is formatted correctly.
Linux hard drives are most commonly formatted to ext4, although other formats are slowly growing in popularity such as btrfs and ZFS. These are Linux-specific file system formats. With USB drives, it’s a different story. To enjoy the maximum flexibility, and to be able to use them on Windows or macOS as well as on Linux, they need to be formatted to something that works in all three operating systems.
Obviously, using a Linux-only format isn’t going to give us what we need. Neither is using an Apple-only format. The closest thing we had to an Esperanto of file storage formats was FAT32. USB drives formatted to this Microsoft standard could be used interchangeably on Windows, Linux, and macOS. That was great until you tried to store a file that happened to be larger than 4GB. That was the fixed, upper-limit file size baked into FAT32.
The exFAT file system overcomes that limitation. It’s another Microsoft format, and it is compatible with macOS and—since kernel 5.4—Linux. That makes it a strong contender for the best file system for USB drives that need to work with the big three operating systems. It doesn’t have the drawbacks of FAT32, but neither does it carry the overheads and extra functionality of NTFS. That makes it fast, too.
As long as you’re on a Linux kernel that is version 5.4 or higher, you’ll be able to use exFAT just as easily as you can any of the other supported file systems. At the time of writing, the current Linux kernel is 5.18, so as long as you have a recently patched and updated system, you’ll be good to go. We’ll demonstrate a graphical method using GNOME Disks, as well as a terminal method.
When you write a new file system onto a USB drive everything on it is erased. That means it is vital that you:
- Verify you don’t care that anything and everything on the USB drive will be erased or ensure that you’ve copied anything you want to keep to another drive.
- Make sure you know which storage device is the one you want to format. Don’t format the wrong drive. It’s an easy mistake to make on a multi-drive computer.
The safest way to begin is with the USB drive unplugged. In Ubuntu, you can press the “Super” key, then type “disks” in the search field. You’ll see the
disks icon. Click the icon to launch the GNOME
disks application lists the storage devices it can find in the left-hand sidebar.
Plug in the USB drive. Linux will detect it, and the change will be reflected in the GNOME
The drive has been added to the list of known storage devices and is correctly identified as a Kingston Data Traveler. The total capacity of this USB drive is 32GB, but it is displayed as 31GB. This is because you lose a little space when you format a drive. Don’t be surprised if the capacity of your USB drive isn’t as much as you expect.
Click on the drive to see some information about it.
We can see that it is formatted with the ext4 file system, and its Linux designation is “/dev/sdc.”
Click on the cogged wheel icon, then click the “Format Partition…” menu option.
Type a name for your USB drive, select the “Other” radio button, then click the “Next” button.
Select the “exFAT” radio button, then click the “Next” button.
You’re warned that the USB drive will be wiped clean, and you’re shown the details of the drive so that you can confirm it is the drive you intend to format. Only when you’re satisfied it is the correct drive, click the red “Format” button.
The drive is formatted for you, and you’re returned to the main
disks display. The entry for the USB drive now shows it is formatted with the exFAT file system.
The first step is to positively identify the USB drive. We can do this using the
lsblk command. Without the USB drive plugged in, run the
Plug the USB drive into the computer and wait a moment for Linux to recognize and mount it. Then run the same
We can see the new entry for the USB drive. It is showing up as device “/dev/sdc”, and it is mounted on “/run/media/dave/MetalUSB.”
Before we can format it, we need to unmount it. We’ll need to use
sudo. Note that there is no “n” in the “umount” command.
We pass the mount point to the
umount command. What this does is unmount the file system. If we use the
lsblk command we’ll see that the USB drive is still recognized, but it is no longer associated with a mount point.
sudo umount /run/media/dave/MetalUSB
To format the USB drive with the new file system, we use the
mkfs.exfat command. We need to reference the USB drive using its device name, which is “/dev/sdc.”
-L (label) option lets us provide a volume label. We’re going to call this USB drive “Metal32.”
sudo mkfs.exfat -L Metal32 /dev/sdc
Unplug the USB drive, wait a moment, then plug it back in. Use the
lsblk command once more and you’ll see the drive is now mounted and the mount point name has changed to reflect the name we chose when we created the file system.
To verify that the file system is indeed exFAT, we can use the df command with the
-T (type) option.
df -T /dev/sdc
We can see the file system is listed as exFAT.
RELATED: How to Use the mkfs Command on Linux
Just to make sure Microsoft Windows was happy with the USB drive we plugged it into a Windows computer and looked at its properties. Windows 10 treated the drive as a functional and correctly-formatted USB drive, using the exFAT file system.
The theoretical maximum size of a file under exFAT is 16EB (Exbibytes). While you’re unlikely to ever need to transport a file of that size, needing to transfer and share files over 4GB is a common enough requirement to make exFAT a good candidate for a universal format for USB drives.
- › Keychron Q8 Mechanical Keyboard Review: An Advanced Keyboard for All Uses
- › Shift+Enter Is a Secret Shortcut Everyone Should Know
- › 10 Hidden Android 13 Features You Might Have Missed
- › 10 Awesome iPad Features You Should Be Using
- › Lenovo ThinkPad Z13 Gen 1 Review: A Vegan Leather Laptop That Means Business
- › 7 Features Android Should Steal From iPhone