-1

I added some new disks, and tried to create new array, using:

mdadm --create /dev/md/2 --level=5 -x 0 --raid-devices=4/dev/sd{a,b,c,g}2

It creates the array, but after reboot - it's gone. What should I do to keep it visible?

Also - I read about spare disks, and so when I see that the raid was created, and it shows (in /proc/mdstat):

md2 : active (auto-read-only) raid5 sdg2[4](S) sdc2[2] sdb2[1] sda2[0]

I understand that sdg2 is treated as spare. But why isn't it automatically rebuilding/syncing the data?

user195086
  • 79
  • 1
  • 1
  • 8

2 Answers2

3

You can add all the arrays found on the system to mdadm.conf so it will be started at each boot:

mdadm --examine --scan >> /etc/mdadm/mdadm.conf

Alternatively, you can run mdadm --examine --scan and add the arrays you want manually in mdadm.conf.

Kl4m
  • 361
  • 2
  • 6
1

This issue could also arise because of device renaming, Try removing the /dev devices from the ARRAY specification and only use the UUID.