Gentoo Archives: gentoo-user

From: Peter Humphrey <peter@××××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Software RAID-1
Date: Mon, 25 Aug 2014 11:18:10
Message-Id: 3397936.PRVjbTIAHa@wstn
In Reply to: Re: [gentoo-user] Software RAID-1 by Peter Humphrey
1 On Monday 25 August 2014 10:22:31 Peter Humphrey wrote:
2 > On Sunday 24 August 2014 19:22:40 Kerin Millar wrote:
3 > > On 24/08/2014 14:51, Peter Humphrey wrote:
4 > --->8
5 >
6 > > > So I decided to clean up /etc/mdadm.conf by adding these lines:
7 > > >
8 > > > DEVICE /dev/sda* /dev/sdb*
9 > > > ARRAY /dev/md5 devices=/dev/sda5,/dev/sdb5
10 > > > ARRAY /dev/md7 devices=/dev/sda7,/dev/sdb7
11 > > > ARRAY /dev/md9 devices=/dev/sda9,/dev/sdb9
12 > >
13 > > Perhaps you should not include /dev/md5 here.
14 >
15 > I wondered about that.
16 >
17 > > As you have made a point of building the array containing the root
18 > > filesystem with 0.99 metadata, ...
19 >
20 > ...as was instructed in the howto at the time...
21 >
22 > > I would assume that it is being assembled in kernelspace as a result of
23 > > CONFIG_MD_AUTODETECT being enabled.
24 >
25 > Yes, I think that's what's happening.
26 >
27 > > Alternatively, perhaps you are using an initramfs.
28 >
29 > Nope.
30 >
31 > > Either way, by the time the mdraid init.d script executes, the /dev/md5
32 > > array must - by definition - be up and mounted. Does it make a
33 > > difference if you add the following line to the config?
34 > >
35 > > AUTO +1.x homehost -all
36 > >
37 > > That will prevent it from considering arrays with 0.99 metadata.
38 >
39 > No, I get the same result. Just a red asterisk at the left end of the line
40 > after "Starting up RAID devices..."
41 >
42 > Now that I look at /etc/init.d/mdraid I see a few things that aren't quite
43 > kosher. The first is that it runs "mdadm -As 2>&1", which returns null after
44 > booting is finished (whence the empty line before the asterisk). Then it
45 > tests for the existence of /dev/md_d*. That also doesn't exist, though
46 > /dev/md* does:
47 >
48 > # ls -l /dev/md*
49 > brw-rw---- 1 root disk 9, 0 Aug 25 10:03 /dev/md0
50 > brw-rw---- 1 root disk 9, 5 Aug 25 10:03 /dev/md5
51 > brw-rw---- 1 root disk 9, 7 Aug 25 10:03 /dev/md7
52 > brw-rw---- 1 root disk 9, 9 Aug 25 10:03 /dev/md9
53 >
54 > /dev/md:
55 > total 0
56 > lrwxrwxrwx 1 root root 6 Aug 25 10:03 5_0 -> ../md5
57 > lrwxrwxrwx 1 root root 6 Aug 25 10:03 7_0 -> ../md7
58 > lrwxrwxrwx 1 root root 6 Aug 25 10:03 9_0 -> ../md9
59 >
60 > Looks like I have some experimenting to do.
61
62 Well, it was simple. I just said "rc-update del mdraid boot" and all is now
63 well. I'd better revisit the docs to see if they still give the same advice.
64
65 --
66 Regards
67 Peter

Replies

Subject Author
Re: [gentoo-user] Software RAID-1 Kerin Millar <kerframil@×××××××××××.uk>