Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
mdadm-4 and initramfs
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
r_pns
n00b
n00b


Joined: 02 Jul 2006
Posts: 33

PostPosted: Fri Jun 07, 2019 2:05 am    Post subject: mdadm-4 and initramfs Reply with quote

I've used for years the following code in initramfs/init:
Code:
mdadm --assemble /dev/md_d3 -u SOME_UUID

mount -o ro /dev/md_d3p1 /root

That is, /root is mounted to a partition of a paritionable MD RAID array. This still works with mdadm-3.4.

But trying to upgrade initramfs to mdadm-4.1, I've got quite a strange result. Initially, mdadm in intitramfs creates something like that:
Code:
brw-rw----  9, 3  /dev/md3
brw-rw----  9, 4  /dev/md3p1
lrwxrwxrwx    12  md_d3p1 -> /dev/md3p1

The array /dev/md3 is then up and running, but
Code:
mdadm --detail /dev/md3p1

says
Code:
Array associated with md device /dev/md3p1 does not exist

Clearly, /dev/md3p1 cannot be mounted. I've also tried auto=mdp option for mdadm to no avail.

But AFTER this failure (from the intramfs busybox shell), I'm SOMETIMES able to manually assemble the array and successfully mount the fs the following way:
Code:
mdadm --stop /dev/md3
rm -r /dev/md*
mdadm --assemble /dev/md_d3 --auto=mdp3 -u SOME_UUID

Now, I have quite different device names and numbers:
Code:
brw-rw----  254, 192  /dev/md_d3
brw-rw----  254, 193  /dev/md_d3p1

Henceforth , the partition md_d3p1 can be mounted successfully.

Many thanks for any help!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum