public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] Udev rules for identical hard drives
@ 2012-08-01 23:34 Alex Schuster
  2012-08-01 23:59 ` Canek Peláez Valdés
  2012-08-02 16:59 ` Walter Dnes
  0 siblings, 2 replies; 22+ messages in thread
From: Alex Schuster @ 2012-08-01 23:34 UTC (permalink / raw
  To: gentoo-user

Hi there!

I do not understand the numbering of my hard drives. There may be some
inherent logic, but whenever I make some changes, like replacing drives,
or changing BIOS settings, the order changes. Maybe it's even more random.

So I made some udev rules like this, and my drives are called /dev/hd1,
hd2 and hd3:

SUBSYSTEMS=="scsi", KERNEL=="sd?", ATTRS{model}=="SAMSUNG HD154UI",
SYMLINK="hd1"

This works fine, and this way I can address them in scripts, smartd and
hdparm config files and such. But now I have two identical drives. I had
this before with the drive above, but while being identical models, the
two drives differed a little in size, so I just had to add ATTR{size}.
This does not help with my current drives, and I find nothing
in /sys/block/sd?/device/ that differs. Could there be another way to
distinguish the drives, like looking at the partition scheme or something?

	Wonko


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2012-08-04  5:52 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-01 23:34 [gentoo-user] Udev rules for identical hard drives Alex Schuster
2012-08-01 23:59 ` Canek Peláez Valdés
2012-08-02  0:01   ` Canek Peláez Valdés
2012-08-02  0:42     ` Alex Schuster
2012-08-02  0:53       ` Canek Peláez Valdés
2012-08-02  9:20         ` Alex Schuster
2012-08-02 10:38           ` Alex Schuster
2012-08-02 13:11             ` Mark Knecht
2012-08-02 15:02               ` Alex Schuster
2012-08-02 15:50                 ` Dale
2012-08-02 18:29                   ` Alex Schuster
2012-08-03  6:40                     ` Dale
2012-08-03 15:31                       ` Paul Hartman
2012-08-04  5:50                         ` Dale
2012-08-02 15:50                 ` Mark Knecht
2012-08-02 17:43                   ` Peter Humphrey
2012-08-02 18:28                     ` Mark Knecht
2012-08-02 18:47                   ` Alex Schuster
2012-08-02 16:59 ` Walter Dnes
2012-08-02 17:43   ` Alex Schuster
2012-08-02 18:57     ` Neil Bothwick
2012-08-02 18:55   ` Neil Bothwick

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox