Re: Controlling the order of /dev/sdX devices?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



The reason for the udev hotplug rule is simply for the purpose of mounting removable devices as read-only.  If udev is left to its devices, everything plugged up is read-write which is verboten in this application.  Unfortunately, there seems to be no way (i've found) to distinguish, at device/bus level, between a system HDD, a hardware RAID volume and an eSATA device and handle the eSATA device uniquely from others.  All eSATA and USB devices _must_ mount read-only.  If everything is lined up at boot, sda and sdb are camped via fstab and udev deals with sdc and above, mounting what are known to be removable devices as r/o.  Shotgun, i know, but there is no way of knowing in advance what devices the system (er, appliance) will see.

tangled, huh?

thanks

- csawyer

Robert Heller heller at deepsoft.com
Thu Mar 31 14:20:55 EDT 2011

    Previous message:  CentOS Digest, Vol 74, Issue 31
    Next message:  figuring out LogVol details for mount
    Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

At Thu, 31 Mar 2011 18:23:00 +0100 CentOS mailing list <centos at centos.org> wrote:

> 
> thanks for the reply, Phil
> 
> It would, were udev not inserting USB and/or eSATA drives at /dev/sdb1
> and/or /dev/sdc1 and exposing the array to the udev rule intended to
> handle only removable devices (at sdc or sdd).  The array then mounts
> unpredictably in /media/xxx-sdc1 or sdd1 - not what is wanted - depend
> on how many removable devices are plugged at the time of rebooting. Of
> course, a single removable device will camp at sdb, which is out of
> reach of udev so the whole hotplug thing is broken until someone removes
> all of the devices at site, allowing a clean boot. 

Do you have some *nonstandard* udev rule for hot plug devices? The
*standard* hotplug udev rules are not tied to specific ranges of sdXX's
-- my IDE-based laptop will properly handle a hot plugged USB device at
/dev/sda for example.

The hot plug logic should also not mess with not hot pluged devices.  If
your RAID array is mounted in /etc/fstab (or has a 'noauto' line in
/etc/fstab with the idea of mounting it manually later or has something
in automount's config for automounting it), the hot plug system should
not touch it, no matter what /dev/sdXX it happens to land at, so long as
you are using volume labels or some such to reference the mountable
volumes.

- cal sawyer
 
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos



[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux