Windows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallOutdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchOn Ubuntu 22.04, mdadm creates and manages Linux software RAID arrays. The safe workflow is: choose a level based on capacity and failure tolerance, verify that the member disks contain no needed data, create the array, monitor its initial sync, save its assembly metadata, and keep tested backups. You can replace failed members and expand many arrays, but reshaping and rebuilding are periods of elevated risk.
Need a server to try this on? Antihost offers Linux VPS plans with NVMe storage, full root access and a 14-day free trial.
What mdadm manages—and what it does not
mdadm controls Linux MD (multiple-device) arrays in the kernel. It writes an MD superblock to each member device, starts synchronization or recovery, and assembles the devices into a logical block device such as /dev/md/data. Ubuntu’s Jammy manual identifies the packaged implementation as mdadm 4.2-0ubuntu2 (Canonical/Ubuntu, accessed 2026).
As an Amazon Associate I earn from qualifying purchases.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →RAID protects availability when a disk fails; it is not a backup. Accidental deletion, filesystem corruption, malware, fire, theft, and an administrator running a destructive command can affect every member simultaneously. Keep at least one independent, tested backup before creating, replacing, reshaping, or dismantling an array.
Choose the RAID level before touching a disk
The level determines usable capacity, minimum disk count, performance characteristics, and how much failure exposure you accept during a rebuild. The capacities below assume equally sized members; a member larger than the others is normally limited to the smallest usable size.
#1 Best Overall
- Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
- Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
- Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
- Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
- 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
| Level | Minimum disks | Approximate usable capacity | Simultaneous member failures tolerated | Performance and rebuild considerations | Best fit |
|---|---|---|---|---|---|
| RAID0 | 2 | Sum of all members | 0 | Striping can deliver high sequential and parallel throughput. Any member failure loses the entire array; there is no rebuild. | Temporary or reproducible data where capacity and speed matter more than availability. |
| RAID1 | 2 | Capacity of one member (with two disks) | One with two members; with more mirrors, every member except the last surviving copy can fail, subject to the array layout | Reads can be served by multiple mirrors. Writes go to each mirror. Rebuilds copy data to a replacement and are generally straightforward. | Boot volumes, small arrays, and workloads that value simple redundancy. |
| RAID5 | 3 | Approximately (number of disks − 1) members | 1 | Distributed single parity saves capacity, but every write may involve parity work. A second failure before recovery completes makes the array unavailable, and a degraded dirty start can leave parity untrustworthy. | Capacity-efficient storage with moderate redundancy and a workload that can accept single-disk protection. |
| RAID6 | 4 | Approximately (number of disks − 2) members | 2 | Dual parity provides more failure margin than RAID5, with additional parity overhead and often slower writes. Rebuilds still stress all members. | Larger arrays where surviving a second disk failure is important. |
| RAID10 | 4 (normally an even number) | About half the raw capacity | At least one disk, and potentially more if failures are in different mirrors; two disks in the same mirror are fatal | Mirroring plus striping gives strong read/write behavior and shorter, more localized rebuilds than parity RAID, at the cost of 50% raw capacity. | Busy applications that need predictable I/O and redundancy rather than maximum capacity. |
RAID level names do not describe the whole design. Disk size, interface, controller or backplane behavior, workload write patterns, and the time required to restore a replacement all affect risk. For a parity array, the Linux kernel documentation specifically warns that starting a degraded, dirty RAID5 or RAID6 can expose inconsistent parity; an explicit --force may be required only after you understand the consequences.
Prepare Ubuntu 22.04 and the member devices
Install and verify mdadm
- Refresh package metadata and install the tool:
sudo apt update && sudo apt install mdadm - Confirm that the command is available:
mdadm --version
During package installation, Ubuntu may ask whether an array should be handled automatically. The important persistence step is still to record the array definition in /etc/mdadm/mdadm.conf and regenerate the initramfs after creation.
Map disks to stable, intended devices
List names, sizes, filesystem signatures, and mount points before selecting anything:
lsblk -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS,UUID
Use the output to distinguish the operating-system disk from the disks intended for RAID. Do not infer identity from a transient name such as /dev/sdb alone: after a reboot or hardware change, Linux can assign letters differently. Check the enclosure, serial numbers, or the detailed device information available on your system.
- Every intended member must be unused and unmounted. Stop services that might have open files on it.
- Creating an array writes metadata and normally makes previous contents inaccessible. Copy off anything you need first.
- Using one partition per disk is often easier to replace and identify than using whole disks. Make each member partition at least as large as the data partition it replaces, and use a partition type appropriate for Linux RAID when your partitioning tool offers one.
- Do not mix devices with different sector sizes or unexpectedly different capacities unless you have a deliberate layout plan. The smallest member size controls the common usable area.
Before issuing --create, run lsblk again and verify each path in your command. A typo can overwrite the wrong disk immediately.
Create an array
The general create form is:
sudo mdadm --create /dev/md/<name> --level=<level> --raid-devices=<n> <device1> <device2> ...
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
For example, this creates a two-member mirror from partitions:
sudo mdadm --create /dev/md/data --level=1 --raid-devices=2 /dev/sdb1 /dev/sdc1
Rank #2
- 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
- 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
- Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
- 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
- What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
For a four-disk RAID10, the corresponding command is:
sudo mdadm --create /dev/md/data --level=10 --raid-devices=4 /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1
Free tools Windows power users keep installed
One-click scans. No signup required.
Replace the name, level, count, and device paths with the values you selected. The Jammy mdadm manual describes create mode as writing per-device superblocks and starting a resynchronization. The array is normally usable while that initial sync runs, but performance can be lower and redundancy is not complete until synchronization finishes.
Never use --force to silence a warning simply to make creation proceed. Stop and determine whether the warning indicates stale metadata, a size mismatch, or a disk that still contains a needed filesystem.
Watch synchronization and verify health
Track the kernel’s progress view
Read the live MD status file:
cat /proc/mdstat
During creation or recovery, the output shows the array, level, member state, a progress percentage, estimated time, and the current speed. Run the command again rather than treating one snapshot as a final result. A line without a resync or recovery operation indicates that the current background operation has ended.
Inspect the complete array detail
Ask mdadm for the authoritative member state:
sudo mdadm --detail /dev/md/data
Check the state, active and working device counts, failed-device count, spare count, and the list of member roles. A healthy synchronized array should show all expected devices active and no failed members. Save this output when diagnosing a problem; it records the array UUID, event information, layout, and device roles.
Do not equate “mounted” with “healthy.” A degraded array can continue serving files while one or more copies or parity members are missing. Set up monitoring appropriate to your server so a degraded state produces an alert rather than waiting for the next disk failure.
Make the array assemble after reboot
After creation, append the array definition detected by mdadm:
Rank #3
- Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
- Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
- Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
- Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
- What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
sudo mdadm --detail --scan | sudo tee -a /etc/mdadm/mdadm.conf
Inspect the file afterward. If you run the command repeatedly, remove duplicate ARRAY entries rather than accumulating them. Then rebuild the initramfs so early boot has the current assembly information:
Recommended Free Tools
sudo update-initramfs -u
Test assembly during a planned maintenance window. Confirm that the expected /dev/md/data device appears before services that depend on it start. If your configuration uses a filesystem in /etc/fstab, reference the filesystem UUID rather than relying on a disk letter.
Create a filesystem and mount the usable device
RAID provides a block device; it does not create a filesystem. Only after the array is assembled should you format it. Formatting destroys anything currently on the array:
- Check the block device and its size:
sudo mdadm --detail /dev/md/data - Create a filesystem appropriate for your workload, for example ext4:
sudo mkfs.ext4 /dev/md/data - Create a mount point and mount it:
sudo mkdir -p /srv/data
sudo mount /dev/md/data /srv/data - Obtain the filesystem UUID with
lsblk -forsudo blkid /dev/md/data, then add a matching UUID entry to/etc/fstab. Test it without rebooting:sudo umount /srv/data && sudo mount -a
Keep the filesystem layer separate in your troubleshooting. An array can be healthy while a filesystem is damaged, and a clean filesystem cannot repair missing or inconsistent RAID members.
Replace a failed RAID member safely
1. Confirm the failure and record the current state
Start with:
sudo mdadm --detail /dev/md/data
cat /proc/mdstat
Identify the exact failed member and its role. If the kernel has dropped a disk because of transport errors, also inspect the system’s hardware and storage logs. Repeated link or power errors can damage a replacement as well.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →2. Mark and remove the old member
If mdadm still considers the device active, mark it failed and remove it:
sudo mdadm /dev/md/data --fail /dev/sdc1
sudo mdadm /dev/md/data --remove /dev/sdc1
Rank #4
- Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
- Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
- Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
- Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
- Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
If the device is already listed as removed or missing, the fail step may not be necessary; do not invent a path for a disk that is no longer present. Confirm that the array is degraded but assembled, and make sure you have a backup before continuing.
3. Install a compatible replacement
The replacement must be at least as large as the member size required by the array. A disk advertised with the same nominal capacity can be a few sectors smaller, so compare actual sizes. Partition it to match the surviving member and use the replacement partition path, such as /dev/sdf1. Do not add the whole disk if the existing array uses partitions unless you intentionally designed it that way.
4. Add the replacement and monitor recovery
Add the new member:
sudo mdadm /dev/md/data --add /dev/sdf1
Then watch the rebuild:
watch -n 5 cat /proc/mdstat
Use sudo mdadm --detail /dev/md/data to confirm that the replacement has moved from spare or rebuilding to active and that the failed-device count returns to zero. Do not remove power or repeatedly reboot during recovery. The array can be used, but heavy application I/O competes with recovery and prolongs exposure. After completion, run a consistency check during a suitable maintenance period if your operational policy calls for one, and verify that monitoring reports a clean array.
Special caution for degraded RAID5 and RAID6
A parity array that was cleanly stopped records enough information to reconstruct missing data. A degraded array that was writing when power failed may have inconsistent parity. Linux kernel RAID documentation warns that starting a degraded, dirty RAID5 or RAID6 can produce unreliable results and may require an explicit --force. That option tells mdadm to proceed despite the uncertainty; it does not repair parity.
Do not issue a forced start from a copy-and-paste recipe. First establish which members contain current data, preserve an image or backup when possible, and determine whether the missing device can be returned. If a forced assembly is unavoidable, document the exact member set and accept that some stripes may be inconsistent. After assembly, copy critical data to independent storage and plan a replacement or rebuild rather than treating the array as trustworthy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Grow an array or reshape its layout
Many MD levels can be expanded with the documented --grow operation. Growth is not a single command: the array reshape must finish, and the filesystem must then be expanded separately. Keep a tested backup, schedule maintenance, and ensure stable power before starting.
Add a member and increase the RAID-device count
For levels that support adding members, add the prepared partition first:
sudo mdadm /dev/md/data --add /dev/sde1
Then change the array’s device count. For example, increasing a three-member RAID5 to four members is:
Best Value
- 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
- Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
- Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
- HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
- What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
sudo mdadm --grow /dev/md/data --raid-devices=4
For a mirror that was created with two members and has an additional member available, the same pattern can increase the mirror count:
sudo mdadm /dev/md/data --add /dev/sdd1
sudo mdadm --grow /dev/md/data --raid-devices=3
Do these 3 things before closing this tab:
1Scan for outdated or missing drivers - takes under a minute2Clear out junk files and repair common Windows errors3Fix the driver behind crashes, sound loss and screen glitchesUse the level’s mdadm documentation and the current mdadm --detail output to confirm that the operation is supported for your layout. Never assume that adding a disk automatically increases usable capacity; until --grow changes the array geometry and completes its reshape, the extra disk may be only a spare.
Monitor the reshape and resize the filesystem
Track reshape or recovery in /proc/mdstat and wait for it to finish before resizing the filesystem. For ext4, resize the filesystem on the MD device:
sudo resize2fs /dev/md/data
Other filesystems have their own online or offline growth procedures. Confirm the filesystem type first and follow its rules; an array resize alone does not make previously unused blocks available to applications.
Changing RAID level or layout is a more consequential reshape than simply adding a same-level member. Test the procedure on an equivalent system, verify the backup, and reserve enough time for all data to be read and rewritten. A second disk failure during a parity reshape can turn a planned capacity upgrade into data recovery.
Stop, dismantle, or repurpose an array
Stopping an array is different from merely unmounting its filesystem. To dismantle it deliberately:
- Stop applications and unmount every filesystem on the array:
sudo umount /srv/data - Confirm that no process is using the mount point and stop the array:
sudo mdadm --stop /dev/md/data - Only after verifying the member paths, erase MD superblocks if the disks are being reused outside this array:
sudo mdadm --zero-superblock /dev/sdb1 /dev/sdc1
Zeroing the wrong device destroys the metadata needed for assembly and can make recovery harder. Remove obsolete array definitions from /etc/mdadm/mdadm.conf, update the initramfs if the old array was included there, and remove or revise its /etc/fstab entry. Never zero superblocks on a live array or on members you may still need for recovery.
Quick Recap
Troubleshoot common mdadm problems
| Symptom | Likely cause | Safe next action |
|---|---|---|
| The create command says a device is busy | A filesystem is mounted, a swap area is active, or another process has the block device open. | Use lsblk to find mounts, stop the dependent service, unmount or disable the use, and verify again. Do not force creation over an unknown process. |
| The array is missing after reboot | Its ARRAY metadata was not saved, the initramfs is stale, or the device paths changed. | Inspect mdadm --detail --scan, /etc/mdadm/mdadm.conf, and /proc/mdstat; regenerate with sudo update-initramfs -u after correcting the definition. |
| A newly added disk remains a spare | The array’s device count was not increased, or the replacement is too small. | Check mdadm --detail, compare exact member sizes, and use the supported --grow --raid-devices=... operation where appropriate. |
| Recovery is extremely slow | Application I/O, conservative kernel speed limits, failing hardware, or a large array can compete with recovery. | Check hardware and logs, keep the host powered, reduce nonessential load, and monitor for read errors. Do not interrupt recovery merely because the estimate changes. |
| The filesystem still shows the old capacity after growth | The filesystem layer has not been resized. | Verify that the MD reshape is complete, identify the filesystem, and run its documented growth command, such as resize2fs for ext4. |
| mdadm reports an inconsistent or dirty parity array | The array was interrupted while writing and is now missing a member. | Do not guess with --force. Preserve data, determine the correct member history, and treat any forced start as a recovery decision rather than a normal repair. |
Operational practices that prevent avoidable loss
- Record the array level, member serial numbers, partition sizes, filesystem UUID, mount point, and backup location in your runbook.
- Test both a file restore and a complete-array recovery procedure. A backup that has never been restored is an assumption, not a recovery plan.
- Alert on degraded, rebuilding, or failed states instead of relying on periodic manual checks of
/proc/mdstat. - Keep replacement media available and match its usable size and interface to the array. A replacement that arrives after a second failure is not protection.
- Schedule disk health checks and investigate read or transport errors before they become member failures.
- Expect lower performance during initial synchronization, rebuilds, and reshapes. Avoid combining a major reshape with unrelated storage maintenance.
- Use RAID for availability and performance characteristics, then use independent backups for recovery from deletion, corruption, and site-level incidents.
A concise management checklist
- Install mdadm and verify the version.
- Identify the correct, unmounted member devices with
lsblk. - Choose RAID level from failure tolerance, usable capacity, workload, and rebuild exposure—not capacity alone.
- Create the array and confirm the command’s device paths before accepting any destructive prompt.
- Monitor
/proc/mdstatand inspectmdadm --detailuntil synchronization completes. - Save the ARRAY definition and regenerate the initramfs.
- Create and mount a filesystem only on the assembled MD device, then configure its UUID in
/etc/fstab. - For a failure, identify the member, fail and remove it, install a same-size-or-larger replacement, add it, and watch recovery.
- For growth, back up first, use the supported
--growsequence, wait for reshape completion, and resize the filesystem separately. - When dismantling, unmount first, stop the array second, and zero superblocks only on verified, intentionally repurposed devices.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




