Gentoo Archives: gentoo-user

From: David W Noon <dwnoon@××××××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] booting - I don't anystand how the (Linux) world works anymore
Date: Sat, 25 Jun 2016 21:06:16
Message-Id: 576EF240.4090209@ntlworld.com
In Reply to: Re: [gentoo-user] booting - I don't anystand how the (Linux) world works anymore by Helmut Jarausch
1 -----BEGIN PGP SIGNED MESSAGE-----
2 Hash: SHA1
3
4 On Sat, 25 Jun 2016 22:18:39 +0200, Helmut Jarausch
5 (jarausch@××××××.be) wrote about "Re: [gentoo-user] booting - I don't
6 anystand how the (Linux) world works anymore" (in
7 <pIgoU9n+PTyazMfaAjTflI@P0zLLCmfwy+atNuDbwD3I>):
8
9 > On 06/25/2016 09:39:32 PM, David W Noon wrote:
10 [snip]
11 >> I always statically link the driver that operates the controller
12 >> that connects the root device and modprobe the drivers that
13 >> operate the other disk controllers. This ensures that the
14 >> controller for my /dev/sda device is probed first and its drives
15 >> get "a", "b" and "c" in /dev/sd?, and those letters are assigned
16 >> in device address order on the controller.
17 >
18 > Thanks Dave, but I do statically link the corresponding device
19 > drivers, as well.
20
21 I should have been more clear: only 1 driver for disk controllers
22 should be statically linked; the others should be modprobed, usually
23 by naming them in /etc/conf.d/modules.
24
25 > But I don't understand why my only hard drive is named sdb?
26
27 Another drive, presumably on another controller, has been hardware
28 probed first.
29
30 The reason I use a mixture of static and dynamic linking is to control
31 the sequence in which the hardware probes are run. If you statically
32 link everything, the kernel can have the drivers run their hardware
33 probes in whatever order it chooses. When they are dynamically linked,
34 the hardware probes occur in the sequence in which the modprobes occur.
35
36 The upshot is that the drives controlled by statically linked drivers
37 are probed first, then the drives controlled by dynamically linked
38 drivers are probed in the order in which the modprobes occur.
39
40 Therefore, I configure my kernels so that the drives get probed in the
41 order I want.
42
43 > It looks as if my kernel named my built-in CDROM device as /dev/sda
44 > .
45
46 An optical drive should be /dev/sr0 or the like. Are you sure it's the
47 CD-ROM drive grabbing the hard drive address? That seems like
48 something the old IDE drivers used to do; if you are using the long
49 obsolete IDE kernel modules, you should really upgrade to the libata
50 drivers.
51
52 > And if I have plugged in an USB drive it seems to influence the
53 > naming scheme, as well.
54
55 Your USB controller's driver appears to be statically linked. This is
56 a seriously bad idea.
57
58 > And, to make it even more complicated, once the system is up, it
59 > has a different naming scheme. E.g. now my internal hard disk has
60 > the name /dev/sda but if I tried to boot by this name it fails.
61
62 That could well be udev/eudev renaming devices during its start-up.
63
64 > For a normal human as me, this is just crazy!
65
66 Well, Gentoo was never meant for normal humans. ... :-)
67 - --
68 Regards,
69
70 Dave [RLU #314465]
71 *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
72 dwnoon@××××××××.com (David W Noon)
73 *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
74
75 -----BEGIN PGP SIGNATURE-----
76 Version: GnuPG v2
77
78 iEYEARECAAYFAldu8j8ACgkQRQ2Fs59Psv8T1gCgtZ76X/QGLPchCKnQ0v5Yoeyf
79 CogAn0EDnbSzGZrdHLLwF1SkO4gqH+yz
80 =BR6C
81 -----END PGP SIGNATURE-----