Reducing mdadm Mirror Drive Count

“Grow” the array down to two devices:

$ sudo mdadm --grow /dev/md1 --raid-devices=2 --backup-file /tmp/mdadmbackup
raid_disks for /dev/md1 set to 2

Show the new status:

/dev/md1:
        Version : 1.2
  Creation Time : Fri Sep 16 22:38:10 2011
     Raid Level : raid1
     Array Size : 1953510841 (1863.01 GiB 2000.40 GB)
  Used Dev Size : 1953510841 (1863.01 GiB 2000.40 GB)
   Raid Devices : 2
  Total Devices : 2
    Persistence : Superblock is persistent

    Update Time : Tue Jul  4 18:27:02 2017
          State : clean 
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           Name : microserver:1  (local to host microserver)
           UUID : e19da472:04736a59:6c1e25ec:c4a60ebe
         Events : 20513

    Number   Major   Minor   RaidDevice State
       3       8       49        0      active sync   /dev/sdd1
       2       8       17        1      active sync   /dev/sdb1

References:



#linux