The solution is to use mkdosfs (mkfs.vfat) : it lets the user specify the volume label using the -n flag, and lowercase letters are kept lowercase, but this tool recreates the filesystem, so all data will be lost.
The non-destructive solution below is a combination of the mlabel and dosfslabel command-line tools.
- Connect the device to the computer if not already connected.
- Open a terminal window.
- Run sudo blkid | grep ' TYPE="vfat"' and
- Unmount the device by running umount /dev/sdb1 (substituting /dev/sdb1 with the name of the device found above). If it was mounted,
and the unmount failed, then close some windows, kill some programs
(e.g. sudo fuser -m /dev/sdb1), and try unmounting again.
- Run sudo env MTOOLS_SKIP_CHECK=1 mlabel -i /dev/sdb1 ::x (substituting /dev/sdb1 with the name of the device found above). If
the system can't find mlabel, then install it by running sudo apt-get
install mtools , and try again.
- Run sudo dosfslabel /dev/sdb1 MyLabel (substituting MyLabel with the desired label and /dev/sdb1 with the name of the device found
above). Ignore any warnings about boot sector differences. If the
system can't find dosfslabel, then install it by running sudo apt-get
install dosfstools , and try again.
- Run sudo blkid | grep ' TYPE="vfat"' , and examine its output to verify that the label has been changed properly. Optionally, unplug
the device, and then plug it back in. The system will recognize it,
and mount it under /media/MyLabel, without converting lowercase
letters in the volume label to uppercase.
Please note that there is an 11 character limit on the length of a VFAT volume label. If you specify a longer label, it will be truncated. There is another restriction: the label can contain only (some) ASCII characters: accented letters etc. won't work.