Gentoo Archives: gentoo-user

From: Mick <michaelkintzios@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] RAID-1 on secondary disks how?
Date: Tue, 29 Jan 2019 09:21:21
Message-Id: 1638893.gl9guai2gr@dell_xps
In Reply to: [gentoo-user] RAID-1 on secondary disks how? by Peter Humphrey
1 Hello Peter,
2
3 On Monday, 28 January 2019 16:56:57 GMT Peter Humphrey wrote:
4 > Hello list,
5
6 > When I run "mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda2
7 > /dev/ sdb2", this is what I get:
8 >
9 > # mdadm --stop /dev/md0
10 > mdadm: stopped /dev/md0
11 > # mdadm: /dev/sda2 appears to contain an ext2fs file system
12 > size=524288000K mtime=Thu Jan 1 01:00:00 1970
13 > mdadm: /dev/sdb2 appears to contain an ext2fs file system
14 > size=524288000K mtime=Thu Jan 1 01:00:00 1970
15 > Continue creating array? y
16 > mdadm: RUN_ARRAY failed: Invalid argument
17
18 Do you have CONFIG_MD_RAID1 (or whatever it should be these days) built in
19 your kernel?
20
21
22 > If I boot from SysRescCD I also get "device /dev/sda2 exists but is not an
23 > md device." I also had to "mdadm --stop /dev/md127" since that OS calls the
24 > first array that.
25
26 The SysRescueCD kernel you boot with does not (yet) have access to an
27 mdadm.conf and is automatically compiling the RAID array with default
28 settings.
29
30
31 > I've tried with a GPT disk header and with an MSDOS one, with similar
32 > results. Also with /etc/init.d/mdraid not running, with it started on my
33 > command and with it in the boot runlevel. Each time I changed anything I
34 > rebooted before trying anything else.
35 >
36 > I must be missing something, in spite of following the wiki instructions.
37 > Can someone help an old duffer out?
38
39 You need to update your initramfs after you configure your array, so your
40 kernel knows what to assemble at boot time when it doesn't yet have access to
41 your mdadm.conf.
42
43 It could help if you examined/posted the contents of your:
44
45 cat /etc/mdadm/mdadm.conf
46 cat /proc/mdstat
47 dmesg |grep md
48 mdadm --detail --scan
49 ls -l /dev/md*
50
51 I haven't worked with RAID for some years now, but going from memory the above
52 should reveal any discrepancies.
53
54 --
55 Regards,
56 Mick

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-user] RAID-1 on secondary disks how? Peter Humphrey <peter@××××××××××××.uk>