mdadm Command Examples

RAID management utility. More information: https://manned.org/mdadm.

sudo mdadm --create {{/dev/md/MyRAID}} --level {{raid_level}} --raid-devices {{number_of_disks}} {{/dev/sdXN}}

sudo mdadm --stop {{/dev/md0}}

sudo mdadm --fail {{/dev/md0}} {{/dev/sdXN}}

sudo mdadm --remove {{/dev/md0}} {{/dev/sdXN}}

sudo mdadm --assemble {{/dev/md0}} {{/dev/sdXN}}

sudo mdadm --detail {{/dev/md0}}

sudo mdadm --zero-superblock {{/dev/sdXN}}