CompTIA Linux+ (XK0-006)System ManagementHard

A storage administrator checks a two-disk RAID 1 array and sees the following output from 'mdadm --detail /dev/md0': 'State: clean, degraded' and one device listed as 'removed'. After replacing the failed physical disk and creating a new partition /dev/sdc1, which command correctly restores full redundancy to the array?

  1. Amdadm --add /dev/md0 /dev/sdc1
  2. Bmdadm --stop /dev/md0
  3. Cmdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sdc1
  4. Dmkfs.ext4 /dev/sdc1
Show answer & explanation

Correct answer: A. mdadm --add /dev/md0 /dev/sdc1

'mdadm --add' adds a new spare/replacement device to an existing degraded array, triggering a resync so the array returns to a fully redundant, healthy state. Using --create would destroy the existing array metadata instead of repairing it.

Why the other options are wrong

  • B. --stop deactivates the array entirely, which is not a repair step.
  • C. --create would build a brand-new array and destroy existing data/metadata rather than repair it.
  • D. Formatting the raw partition directly bypasses RAID membership and won't repair the array.

mdadm RAID Recovery

When a RAID array becomes degraded due to a failed disk, mdadm --add integrates a replacement device and triggers resynchronization to restore redundancy.

  • mdadm --detail shows array state (clean, degraded, etc.)
  • --add re-adds a replacement/spare disk to an existing array
  • --create only be used for building a new array, not repairing one

Memory trick: --add = 'adopting' a new disk into the existing RAID family after a loss

More System Management questions