A volume label is the name assigned to a storage device volume that helps users identify different storage media, such as hard drives, USB flash drives, or other types of storage devices. The naming of volume labels can be done in a variety of ways, including the graphical interface of the operating system, command-line tools, and so on. Here's how to name or change volume labels in some common operating systems:
windows
Through File Explorer (graphical interface).
Open File Explorer.
Locate the drive to which you want to change the volume label.
Right-click on the drive and select "Properties".
In the General tab, you'll see the Label field, where you can enter a new label.
Once you have entered a new label, click "Apply" or "OK" to save the changes.
From the command line
Open a command prompt (run as administrator).
Use the label command to change the volume label. The command format is: label [drive:] volume label]. For example, to change the volume label of the E drive to "mydrive", you can enter label e: mydrive.
macos
Through the finder
Open the Finder.
In the sidebar, find the drive for which you want to change the volume label.
Click on the drive name and then tap again (or click and wait for a moment) to make it editable.
Enter a new label, then press enter or click on an empty space to save your changes.
Through the terminal
Open the Terminal app.
Use the diskutil command to change the volume label. The command format is: diskutil rename [current volume label] [new volume label]. For example, to change the volume label "myvolume" to "newvolume", you can enter diskutil rename"myvolume" "newvolume"。
linux
From the command line
In Linux, the command to change the volume label depends on the file system type (e.g., ext4, fat32, etc.).
For ext series file systems (e.g., ext2, ext3, ext4), you can use the e2label command. For example, to change the volume label of an ext4 file system, use sudo e2label dev sdx1 newlabel, where dev sdx1 is your partition name and newlabel is the new volume label.
For FAT32 file systems, you can use the dosfslabel command. For example, sudo dosfslabel dev sdx1 newlabel.
Before using the command line to change the volume label, make sure you know the exact file system type and device name of the partition or drive you want to change.
Naming conventions and recommendations
Try to use meaningful names to make it easier to identify different drives and partitions.
Avoid using special characters, as some operating systems may not support them.
Keep the length of the label within the operating system allow (e.g., a maximum of 11 characters for FAT32 and 32 characters for NTFS in Windows).
With the above methods, you can easily name or change the volume label for your storage volume to improve the convenience and efficiency of daily use.