When you physically install a brand-new hard drive into a Linux server, the kernel assigns it a generic, chaotic device name like /dev/sdb1 or /dev/nvme0n1p2. These block names are highly unstable. If you unplug the drive and plug it into a different USB port, the kernel will aggressively rename it to /dev/sdc1, instantly breaking any automated mount scripts or fstab configurations you have created. To mount a hard drive permanently and safely, you must identify its unique mathematical fingerprint using the blkid (Block ID) command.
Understanding UUIDs
Every single time you format a hard drive partition (whether it is ext4, FAT32, or NTFS), the formatting utility permanently burns a Universally Unique Identifier (UUID) into the absolute lowest sector of the disk. A UUID is a chaotic string of 32 alphanumeric characters separated by hyphens (e.g., 1b4e28ba-2fa1-11d2-883f-b9a761bde3fb). Because this massive mathematical string is statistically impossible to duplicate, the kernel can use it to definitively identify the exact physical piece of hardware, regardless of what physical port it is plugged into.
How to Locate a UUID
To extract this critical UUID from your hardware, you must run the blkid command with root privileges.
sudo blkid
The kernel will instantly scan the motherboard, interrogate every single physical storage device attached to the machine, and output a highly dense block of text.
/dev/sda1: UUID="9a3f-11d2-883f" TYPE="ext4" PARTUUID="000a3b"
/dev/sdb1: LABEL="Backup_Drive" UUID="72B4-9F81" TYPE="vfat"
By reading this output, you can instantly confirm the exact file system format (e.g., vfat) and copy the exact UUID string.
Filtering the Output
If you are managing an enterprise database server with 24 individual hard drives, running a raw blkid command will flood your terminal screen with hundreds of lines of chaotic data. You can forcefully restrict the command to interrogate only one specific physical drive.
sudo blkid /dev/sdb1
This command targets only the secondary hard drive, outputting only its specific UUID. Once you have successfully copied the UUID string to your clipboard, you can safely paste it into your /etc/fstab file (using the syntax UUID=72B4-9F81 /mnt/backup vfat defaults 0 0) to guarantee the drive is permanently mounted correctly every single time the server reboots.