Gentoo Archives: gentoo-user

From: "Boyd Stephen Smith Jr." <bss03@××××××××××.net>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] re-scanning for devices
Date: Sun, 26 Feb 2006 06:41:05
Message-Id: 200602260036.00303.bss03@volumehost.net
In Reply to: Re: [gentoo-user] re-scanning for devices by Nick Smith
1 On Sunday 26 February 2006 00:14, "Nick Smith" <nick.smith79@×××××.com>
2 wrote about 'Re: [gentoo-user] re-scanning for devices':
3 > > > also, what if it detects a drive as sda, and i want it to be sdb? is
4 > > > there a way i can tell it what i want to be sda, sda etc? without
5 > > > actually having to move the drives around?
6 > >
7 > > Write udev rules to create persistent device names.
8 >
9 > its actually running a 2.4 kernel on sparc, and i dont think they use
10 > udev, i think they are still on devfs. IIRC. is udev the only way to
11 > accomplish this?
12
13 Yes, which is one of the main reasons users and distributions wanted to get
14 away from devfs. devfs always uses the kernel name for the device, which
15 depends on the order the devices are detected, which depends on module
16 loading order and physical device arrangement.
17
18 With sysfs around it would be possible to find out the kernel name of a
19 device based on persistent attributes which intelligent find and grep-ing.
20 That would be a "pull" way of doing what udev does in a "push" way.
21
22 In this case, it's fairly clear (to me, I suppose this could be just my
23 opinion) that the push way is more efficient and less-error prone.
24
25 Depending on you exact needs, you may be able to use UUIDs and filesystem
26 labels, instead of persistent device nodes. Recent versions of mount will
27 scan for either [including when invoked based on fstab], LVM, EVMS, and
28 mdadm use UUIDs rather than device names. The mini-tool findfs, provided
29 on my system by e2fsprogs (weird), is able to map either to a device name
30 (despite the package that provides it, it does successfully find my reiser
31 filesystems on LVM by either).
32
33 --
34 Boyd Stephen Smith Jr.
35 bss03@××××××××××.net
36 ICQ: 514984 YM/AIM: DaTwinkDaddy
37 --
38 gentoo-user@g.o mailing list