Linuxcat.org

Full Version: super minor mdadm array preferred minor incorrectly named / rename
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
In our situation a webserver crashed so we built a new centos server

server had md0 (boot) comprised of sda1 and sdb1
server had md1 (swap) comprised of sda3 and sdb3
server had md2 (root) comprised of sda2 and sdb2

We booted the machine on a live linux recovery CD with one of the old hard drives to rsync the data across, when completed the system was rebooted to run off its own OS and then proceed to Kernel panic.

this was because md0 has become md125 and md2 has become md127

to resolve, the system was booted of the Centos install disc and linux rescue selected, rescue mode could not see hardly anything in this case, /proc and tempfs was about it. some researching was done which indicated this was a problem of the preferential minor number for the raid devices, but the shell commands to rectify this didn't do the trick.

instead this was the procedure:

mdadm --detail --scan (to show the failed names and their uuids)

then mdadm --stop /dev/md125

then mdadm --assemble --uuid=uuidfrompreviouscommand --update=super-minor /dev/md0

when the first raid device was reset, the remaining problem device was renamed from md127 to md126

so then, mdadm --stop /dev/md126

then mdadm --assemble --uuid=uuidfrompreviouscommand --update=super-minor /dev/md2

Reboot.


You should now be able to boot into your server environment again Smile
Reference URL's