Labeling disks

John Nielsen lists at jnielsen.net
Wed Mar 13 16:53:41 MDT 2013


I have a server that will ultimately contain 20+ 3TB hard drives. Each drive will have its own filesystem (no RAID, etc). Any given drive should not be affected by the presence or absence of any other drives. The drives are data-only, not boot. I would like to label (or otherwise manage) the drives such that:
	* They have human-readable names
	* I won't need to update /etc/fstab when the device names change (e.g. due to hot-swap)
	* I have a quick idea what slot the drive is (supposed to be) in

I have a few ideas but I'm looking for additional suggestions or opinions. How do you deal with large numbers of drives in a system?

i had hoped that /dev/disk/by-label would have the answer but so far I'm disappointed. by-id, by-path, and by-uuid are nothing close to human-readable.

by-label might work but if possible I'd like to be able to e.g. write a new filesystem to a drive without having to remember to supply exactly the same filesystem label.

GPT partition labels seem like they would work but I haven't been able to map them to something I could put in fstab (am I missing something?).

Using LVM would give me what I'm looking for, but I really would just use it for the naming so it seems kind of silly:
	- each drive would be its own volume group
	- each volume group would have exactly one logical volume

Any other suggestions, comments or opinions very much appreciated.

JN



More information about the PLUG mailing list