Sample Header Ad - 728x90

Extending RAID0 with `mdadm --create --assume-clean`?

3 votes
1 answer
5900 views
I had a 1-disk RAID0 array that I created with a view of adding more disks to it eventually, that was working normally. I created it with (approximately): $ mdadm --create /dev/md0 --raid-devices=1 --level=0 /dev/sdb -f Then I added another disk to it with: $ mdadm --grow /dev/md0 --add /dev/sdc --raid-devices=2 and, as per manual, mdadm converted the array to RAID4 and started re-syncing. The manual says that the array will be converted back to RAID0 later. However, /etc/mdstat says it will take 2-3 days for a full re-sync, and I'm wondering whether it is possible instead to stop the array, kill the superblock on /dev/sdc, and do something like: $ mdadm --create --assume-clean --verbose /dev/md0 --chunk=512 \ --level=0 --raid-devices=2 /dev/sdb /dev/sdc instead of waiting for the useless RAID4 re-sync? Right now, the array state is: $ mdadm --detail /dev/md0 /dev/md0: Version : 1.2 Creation Time : XXXXXXXXXXXXXXXX Raid Level : raid4 Array Size : 11718754304 (11175.88 GiB 12000.00 GB) Used Dev Size : 11718754304 (11175.88 GiB 12000.00 GB) Raid Devices : 3 Total Devices : 2 Update Time : XXXXXXXXXXXXXXXX State : clean, FAILED, reshaping Active Devices : 1 Working Devices : 2 Failed Devices : 0 Spare Devices : 1 Chunk Size : 512K sistency Policy : resync Reshape Status : 2% complete Delta Devices : 1, (2->3) ... [root@centos7 ~]# mdadm --stop /dev/md0 [root@centos7 ~]# mdadm -E /dev/sdb /dev/sdb: Magic : a92b4efc Version : 1.2 Feature Map : 0x44 Array UUID : 5978222a:8f2c320c:c7059108:c3d6dc41 Name : centos7:0 (local to host centos7) Creation Time : Sat Apr 28 05:15:00 2018 Raid Level : raid4 Raid Devices : 3 Avail Dev Size : 23437508608 (11175.88 GiB 12000.00 GB) Array Size : 23437508608 (22351.75 GiB 24000.01 GB) Data Offset : 262144 sectors New Offset : 260096 sectors Super Offset : 8 sectors State : clean Device UUID : 9a75cd7e:bb469dab:2e0db890:69a68f54 Reshape pos'n : 620094464 (591.37 GiB 634.98 GB) Delta Devices : 1 (2->3) Update Time : Wed Aug 1 06:12:00 2018 Bad Block Log : 512 entries available at offset 8 sectors Checksum : d239a780 - correct Events : 608 Chunk Size : 512K Device Role : Active device 0 Array State : AA. ('A' == active, '.' == missing, 'R' == replacing) [root@centos7 ~]# mdadm -E /dev/sdc /dev/sdc: Magic : a92b4efc Version : 1.2 Feature Map : 0x46 Array UUID : 5978222a:8f2c320c:c7059108:c3d6dc41 Name : centos7:0 (local to host centos7) Creation Time : Sat Apr 28 05:15:00 2018 Raid Level : raid4 Raid Devices : 3 Avail Dev Size : 23437508608 (11175.88 GiB 12000.00 GB) Array Size : 23437508608 (22351.75 GiB 24000.01 GB) Data Offset : 262144 sectors New Offset : 260096 sectors Super Offset : 8 sectors Recovery Offset : 620094464 sectors State : clean Device UUID : ce6e93f9:729557dc:a1afc6a4:39b954f9 Reshape pos'n : 620094464 (591.37 GiB 634.98 GB) Delta Devices : 1 (2->3) Update Time : Wed Aug 1 06:12:00 2018 Bad Block Log : 512 entries available at offset 264 sectors Checksum : 5b8389b4 - correct Events : 608 Chunk Size : 512K Device Role : Active device 1 Array State : AA. ('A' == active, '.' == missing, 'R' == replacing)
Asked by Anton Tykhyy (133 rep)
Aug 1, 2018, 11:09 AM
Last activity: Aug 1, 2018, 11:57 AM