You are not logged in.
After 2 years of using Archlinux on laptops (although still a newbie) I thought I would try it on my main machine. Never asked a question on these forums as usually all answers here, but now I am stuck.
Setup is fakeraid using mdadm. From /dev/as[ab] made a RAID0 (/dev/md125) which works and boots up Archlinux and Windows. RAID1 (/dev/md126) is for my data storage.
cat /proc/mdstat
md125 : active raid0 sda[1] sdb[0]
904921088 blocks super external:/md127/0 128k chunks
md126 : active (read-only) raid1 sda[1] sdb[0]
524297216 blocks super external:/md127/1 [2/2] [UU]
md127 : inactive sda[1](S) sdb[0](S)
5024 blocks super external:imsm
unused devices: <none>
Cannot do anything to mount partition on md126 to write (can be mounted for read only).
mdadm --readwrite /dev/md126 reports no errors, but md126 remain read only
However, after:
mdadm --stop /dev/md126
sudo mdadm --assemble --scan
It works, and mountable for write!
After reassemble:
cat /proc/mdstat
md125 : active raid0 sda[1] sdb[0]
904921088 blocks super external:/md127/0 128k chunks
Relevant /etc/mkinitcpio.conf
MODULES="dm_mod raid0 raid1 ext4 piix"
FILES="/etc/mdadm.conf"
HOOKS="base udev autodetect pata scsi sata filesystems usbinput mdadm_udev"
mdstat --detail /dev/md126
/dev/md126:
Container : /dev/md/imsm0, member 1
Raid Level : raid1
Array Size : 524297216 (500.01 GiB 536.88 GB)
Used Dev Size : 524297348 (500.01 GiB 536.88 GB)
Raid Devices : 2
Total Devices : 2
State : clean
Active Devices : 2
Working Devices : 2
Failed Devices : 0
Spare Devices : 0
UUID : 19ffe6ac:b17ac771:c8f6de71:7e7f0eb6
Number Major Minor RaidDevice State
1 8 0 0 active sync /dev/sda
0 8 16 1 active sync /dev/sdb
cat /etc/mdadm.conf
ARRAY /dev/md/imsm0 metadata=imsm UUID=519871c0:298af950:19d92799:ba926f0d
ARRAY /dev/md/Volume0 container=/dev/md/imsm0 member=0 UUID=b59ca13e:b4c47dc8:0eac16bc:ee37fea4
ARRAY /dev/md/Volume1 container=/dev/md/imsm0 member=1 UUID=19ffe6ac:b17ac771:c8f6de71:7e7f0eb6
Now if I reboot, md126 becomes read-only again.
I wonder if I need something else in mkinitcpio.conf. Any advice of where else I should look would be helpful.
Last edited by poppyfields (2012-03-05 10:34:23)
Offline
Yes, yes, imsm raids tend to do that. Before the mdadm_udev hook mdassemble segfaulted so I couldn't even use MDraid and had to use DM-raid.
Running `mdmon md127` should cause it to become auto-read-only, and the next read-write mount makes it writable.
It seems that adding /sbin/mdmon to BINARIES in mkinitcpio.conf fixes this, since it will also be executed. So give that a try
However, you have to make sure that before the last poweroff/reboot command in the shutdown process, the raid mounts are all at least remounted as read-only, otherwise it tends to always want to resync the raid on boot...
Or at least it does here...
(imsm-)raids are annoying.
Last edited by Blµb (2012-03-05 10:08:09)
You know you're paranoid when you start thinking random letters while typing a password.
A good post about vim
Python has no multithreading.
Offline
Thanks for the advice - it worked. I had a lot of segfaulted errors and therefore used mdadm_udev. Been thinking of getting a dedicated hardware RAID card to avoid all this in future. It took over a week to sort the RAID issues out for me. At least it woks (for now ). Have to say - great support on this forum!
Offline