exfatlabel
Set or display exFAT volume label
TLDR
Display the current filesystem label
Set the filesystem label
SYNOPSIS
exfatlabel [-i] [-n] [-v] device [label]
PARAMETERS
-i
Print current volume label instead of setting.
-n
Dry-run: no modification, checks label validity.
-v
Verbose mode: print detailed operation info.
-h, --help
Display usage summary.
--version
Show version information.
DESCRIPTION
exfatlabel is a command-line utility for managing volume labels on exFAT filesystems, commonly used on USB drives, SD cards, and external storage. exFAT (Extensible File Allocation Table), developed by Microsoft, supports large files (>4GB) and partitions up to 128PB, making it ideal for flash media.
The tool sets a new label if provided or displays the current one. Labels are limited to 11 UTF-16 characters (22 bytes). It requires root privileges and the target device must be unmounted to avoid corruption. Linux exFAT support depends on kernel modules and userspace tools like exfatprogs.
Basic usage: sudo exfatlabel /dev/sdb1 "MyDrive" renames the label. Use -i to inspect without changes. Verbose output with -v shows operations. Dry-run mode -n validates label length without writing.
Ensure exFAT tools are installed (e.g., apt install exfatprogs). Not compatible with FAT32 or NTFS; use fatlabel or ntfslabel instead.
CAVEATS
Device must be unmounted; run as root (sudo). Label max 11 UTF-16 chars. Requires kernel exFAT support (≥5.7) and exfatprogs/exfat-utils. Risk of data loss if misused on mounted/wrong device.
EXAMPLES
sudo exfatlabel /dev/sdb1 "BackupUSB"
exfatlabel -i /dev/sdb1
sudo exfatlabel -n -v /dev/sdb1 "TooLongLabel" (dry-run test)
REQUIREMENTS
Install exfatprogs or exfat-utils. Load exfat kernel module if needed: modprobe exfat.
HISTORY
Originated in third-party exfat-utils (2013, Namjae Jeon). Replaced by Samsung's exfatprogs (2020+). Official Linux kernel exFAT driver merged in 5.4/5.7 (read-only then full). Now standard in most distros.
SEE ALSO
mkfs.exfat(8), fsck.exfat(8), dumpexfat(8), fatlabel(8), blkid(1)


