Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have Ubuntu Server 10.04 1 system disk, and 5 disks in RAID-5 configuration. The problem is that names of these disks are changed from time to time, they are being randomly mixed from time to time (sda,b,c,d,e,f - so system disks might be sda, or sdc at different time for example)....

is there any way to fix drive names, so that even if it's disconnected for example, no other drive can occupy this letter based on disk UUID or something?

share|improve this question
Why do you want that? No program should rely on those names; that's what UUIDs are for. – htorque Mar 2 '11 at 11:51
Every time I see a dropped drive or check munin performance graphs - I have to use these names, and these are different... – BarsMonster Mar 2 '11 at 13:09
up vote 4 down vote accepted

It's best to always refer to the disks by UUID; you can use the symlinks in /dev/disk/by-uuid/ (or by-id if that's more suitable) to refer to the device nodes.

The /dev/sdxN names are never guaranteed to be consistent, so relying on fixed names is not a good idea.

share|improve this answer

IF you do insist on stable names you may be able to use udev rules to fix the names on mount. In your case you may need to use serial numbers or something equivelent to identify the disks.

I don't know if upstart will be taking over disk mounting. If so, you would need to implement the equivalent rules there.

Alternatively, you could create symlinks to /dev/disk/by-uuid to use for monitoring.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.