mdadm - moving raid 1 from one machine to another

If none of the more specific forums is the right place to ask

mdadm - moving raid 1 from one machine to another

Postby PlunderingPirate9000 » 2020-10-25 19:51

Hi, I'm wondering if you can help me with an issue I'm having with a raid 1 mdadm array.

I attempted to move this array to another (also debian machine) - plugged the SSD pair into a controller, and booted the system.

After the system had booted the drives would not assemble with mdadm --assemble --scan. I opened gparted to take a look at the drives and they appeared as "blank" (unallocated) drives.

I then put them back in the original system to see if they would boot up as normal there - no luck.

Tried mdadm --misc --examine, the two relevant disks sdg/sdh state that there is 1 partition[0] but no raid superblock / magic number.

Not 100 % sure what to do next and I really do not want to lose the data on these disks - so I'm hoping to get some expert advice so I don't break something irreversibly. Cheers
PlunderingPirate9000
 
Posts: 31
Joined: 2017-11-30 15:17

Re: mdadm - moving raid 1 from one machine to another

Postby p.H » 2020-10-26 08:42

Is this related with your previous topic RAID superblocks being wiped on reboot ?
You know how to print the partition tables and metadata signatures on drives and partitions with commands such as
Code: Select all
fdisk -l <drive>
file -skL <drive or partition>
blkid <drive or partition>
wipefs <drive or partition>
mdadm --examine <drive or partition>


PS: you should not reply to spam but only report it so that a moderator can delete it. Now the spam is in your reply.
p.H
 
Posts: 1521
Joined: 2017-09-17 07:12

Re: mdadm - moving raid 1 from one machine to another

Postby PlunderingPirate9000 » 2020-10-26 09:22

Solution: (may only work under certain circumstances)

Code: Select all
sudo mdadm --create --verbose --force /dev/md0 --level=1 --raid-devices=1 /dev/sdg
PlunderingPirate9000
 
Posts: 31
Joined: 2017-11-30 15:17

Re: mdadm - moving raid 1 from one machine to another

Postby p.H » 2020-10-26 11:20

How is that a solution ?
It creates a new array using only one drive, i.e. without any redundancy.
p.H
 
Posts: 1521
Joined: 2017-09-17 07:12


Return to General Questions

Who is online

Users browsing this forum: MagicPoulp and 29 guests

fashionable