Two drives, one set of data, and no panic when one of them dies. That is the promise of RAID 1, and on a Windows 11 PC you can build it in under an hour without buying a RAID card or touching your motherboard firmware. This tutorial walks through a software mirror built with Storage Spaces, the feature that ships inside every edition of Windows 11, including Home.
You will inventory your drives, wipe them cleanly, create a pool, carve out a two-way mirror, format it, break it on purpose, and rebuild it. By the end you will also have two PowerShell scripts: one that builds the mirror in a single run, and one that checks its health every morning and writes a warning to the Windows event log when something drifts.
One caveat before the first command. A mirror protects you from a drive failing. It does not protect you from deleted files, ransomware, a power surge, or a bad update. Keep that in mind as you work through the steps, and browse the rest of our hardware guides if you also need help with storage upgrades, drive health, or NAS builds.
What RAID 1 on Windows 11 Actually Does
RAID 1 writes every block of data to two drives at the same time. If drive A dies, drive B holds a complete copy and the volume keeps running. You replace the dead drive, tell the system to resync, and the mirror returns to full strength. Reads can come from either copy, so a mirror often reads a little faster than a single drive. Writes land on both, so write speed roughly matches the slower of the two.
The cost is capacity. Two 4 TB drives in a mirror give you 4 TB of usable space, not 8 TB. You pay for redundancy with half your raw storage. For photo archives, project files, a game library you do not want to re-download, or a small business shared folder, that trade is usually worth it. Large installs are the clearest example. Players who saw the reported GTA 6 download size and started planning storage know how painful a multi-day re-download becomes after a drive failure.
Windows 11 offers three ways to get a mirror. Storage Spaces is the software route Microsoft steers new setups toward, and it works in every edition. Dynamic disk mirrors are the older route, available on Pro and above, and Microsoft treats them as legacy. Firmware RAID, set up through your motherboard’s BIOS options, hands the job to the chipset driver. This guide uses Storage Spaces because it needs no BIOS changes, survives a motherboard swap, and gives you PowerShell controls for everything.
Under the hood, Storage Spaces gathers your physical drives into a pool, slices the pool into small chunks called slabs, and then places two copies of each slab on two different drives. You never see the slabs. You see a virtual disk, which Windows partitions and formats like any other. Because the layout lives in metadata stored on the member drives themselves, the pool can follow the drives to a different PC.
A mirror is also not a boot solution. Storage Spaces volumes cannot hold the Windows system partition, so your C: drive stays a normal single drive. The mirror becomes a second volume (say, D: or M:) for data. If you need a mirrored boot drive, you need firmware RAID or a hardware controller, and that is a different project with different risks.
Prerequisites: Hardware, Software and Versions
You do not need exotic gear. You do need two drives you are willing to erase, and a few minutes of discipline before you start. Here is the full checklist.
- Operating system: Windows 11 Home, Pro, or Enterprise on a currently supported release. Storage Spaces is present in all of them.
- Shell: Windows PowerShell, which is built into Windows 11. The scripts in this tutorial target it. Newer PowerShell releases can run the storage cmdlets, but the event log commands in the monitoring script need the inbox shell.
- Two drives: SATA SSDs, SATA hard drives, or NVMe drives. Matching models and sizes are ideal. Different sizes work, but the mirror only offers the smaller drive’s capacity.
- Connection: Internal SATA or NVMe. External USB drives can join a pool, but USB bridges drop out under load, and a dropped member turns a healthy mirror into a degraded one. Avoid them for anything you care about.
- Administrator rights: Every step that touches disks needs an elevated session.
- A backup destination: An external drive or cloud account that holds a separate copy of everything you plan to put on the mirror.
- smartmontools (optional): The latest release from the project’s download page gives you
smartctlfor deeper drive health checks. CrystalDiskInfo does the same job with a GUI. - Time: Short for the setup itself, plus resync time for large drives. Initial pool creation is fast. The first full sync of a big hard drive pair can run for hours in the background.
Check your edition first. Press Win + R, type winver, and read the dialog. Then open a terminal as administrator and run $PSVersionTable.PSVersion to confirm the built-in shell is available. If you are on a laptop with a single M.2 slot, stop here. You cannot mirror inside one chassis without a second internal drive, and a USB enclosure is the fragile workaround described above.
Power matters too. A desktop on a surge strip with no battery backup can tear a write in half when the lights flicker. A mirror handles a single drive failing, but a sudden power cut can leave both copies mid-write. A small UPS is the cheapest insurance you can add to this project, and it makes the monitoring script in the last section far less likely to ever fire.
Pick Your Mirror Method and Plan Capacity
Before you wipe anything, make sure Storage Spaces is the right tool for your machine. The three methods differ in portability, edition support, and what happens when hardware changes. The table below summarizes the trade-offs as they apply to a Windows 11 desktop.
| Method | Editions | Needs BIOS change | Can hold Windows | Survives a motherboard swap | Best for |
|---|---|---|---|---|---|
| Storage Spaces (two-way mirror) | Home, Pro, Enterprise | No | No | Yes, the pool imports on another computer | Data volumes, media, project files |
| Disk Management dynamic mirror | Pro and above | No | No (data disks only in practice) | Often, but dynamic disks import less cleanly | Legacy setups you already run |
| Firmware RAID (motherboard chipset) | All, driver required | Yes (SATA or NVMe mode set to RAID) | Yes, with the right driver at install | Usually no, tied to the chipset family | A mirrored boot drive on one board |
| Hardware RAID card | All, driver required | Sometimes | Yes | Only with the same card family | Servers and workstations |
Storage Spaces wins for most home and small-office cases. It lives in the operating system, so a new motherboard does not strand your data. You can plug the two drives into another Windows 11 PC and the pool shows up, ready to import. Firmware RAID is tied to the chipset that created it, and swapping the board often means rebuilding from backup.
The one thing Storage Spaces will not do is protect the drive Windows boots from. If that is your goal, you are in firmware RAID territory, and you should switch the SATA mode before installing Windows. Changing it afterward on an existing install commonly produces an INACCESSIBLE_BOOT_DEVICE blue screen because the matching storage driver is not loaded yet. For everything in this guide, leave your BIOS storage mode alone.
A quick word on SSDs versus hard drives. Mirroring two SSDs gives you fast, quiet redundancy, but SSDs tend to wear at similar rates when they receive identical writes, so a pair bought together can approach end of life together. With hard drives, buying from different batches or even different models of the same class lowers the odds that both fail in the same month. Mirrors reward a little diversity.
Capacity Planning: What Each Drive Pair Gives You
People often misjudge capacity because they remember the old rule of thumb for mirrors without applying it to mismatched drives. A two-way mirror stores each block on two different physical drives, so usable space is limited by the smaller member in a two-drive pool. The table below shows the arithmetic using round example sizes. Real drives report slightly less than their label because manufacturers count decimal terabytes and Windows counts binary ones, and the pool also reserves a little for metadata.
| Drive pair (labeled size) | Raw total | Usable in two-way mirror | Space left unused | Verdict |
|---|---|---|---|---|
| 2 TB + 2 TB | 4 TB | about 2 TB | none | Ideal, matched pair |
| 4 TB + 4 TB | 8 TB | about 4 TB | none | Ideal, matched pair |
| 2 TB + 4 TB | 6 TB | about 2 TB | about 2 TB wasted | Works, but wastes half the larger drive |
| Small SSD + large hard drive | Not listed | Not listed | Not listed | Poor idea, writes drop to hard drive pace |
| 8 TB + 8 TB | 16 TB | about 8 TB | none | Fine, expect long resyncs |
The last row hints at a second planning factor: rebuild time. A repair copies every used block onto the replacement. On an SSD that finishes in minutes to under an hour. On a large hard drive it can run for many hours, during which the mirror has no redundancy. Capacity and risk move together, so a very large mirror is a good case for also keeping a recent backup outside the box.
If you plan to grow later, think about it now. Storage Spaces lets you add more drives to a pool, but a fixed-size mirror does not stretch on its own. A common growth path is to build a second mirror pair, then move data across. Another is to create the original space smaller than the maximum, leaving headroom. Neither is hard, but both go easier when you decide before the first copy.
Steps 1 and 2: Inventory Your Drives and Back Up Everything
Step 1: List every physical disk. Open Windows Terminal as administrator and run the command below. It prints each disk with its type, size, health, and whether it is eligible for pooling. The CanPool column is the one to watch. A disk that holds a Windows partition or has an old pool signature will show False with a reason.
Get-PhysicalDisk | Sort-Object DeviceId |
Format-Table DeviceId, FriendlyName, MediaType, BusType, `
@{n='SizeGB';e={[math]::Round($_.Size/1GB)}}, `
HealthStatus, OperationalStatus, CanPool, CannotPoolReason -AutoSize
A typical result on a desktop with a boot SSD and two new data drives looks like this. The sizes and model names are an illustration, so expect your own values.
DeviceId FriendlyName MediaType BusType SizeGB HealthStatus OperationalStatus CanPool CannotPoolReason
-------- ------------ --------- ------- ------ ------------ ----------------- ------- ----------------
0 Samsung SSD 990 SSD NVMe 932 Healthy OK False Boot Disk
1 WD Red Plus 4TB HDD SATA 3726 Healthy OK True
2 WD Red Plus 4TB HDD SATA 3726 Healthy OK True
Write down the DeviceId and FriendlyName of the two drives you plan to use. If two drives share the same model name, note their serial numbers as well with Get-PhysicalDisk | Select FriendlyName, SerialNumber. When a mirror degrades months from now, you will need to know which physical drive to pull, and a sticker on the case with the last four serial digits saves a guessing game.
Step 2: Back up anything on those drives. Pool creation formats the member drives. If either one holds files you want, copy them to a third location right now and verify the copy by opening a few files from the backup. This is also the moment to decide on your real backup plan, because a mirror will never be one. Cloud sync services cover offsite copies and version history for documents. For bulk media, an external drive stored in a different room works fine.
Treat this step as a gate. Do not move on until you can name the location of your backup and confirm the copy opens. People who skip it tend to learn the difference between redundancy and backup at a bad moment, usually when a mistaken delete replicates instantly to both mirror halves.
Steps 3 and 4: Baseline Drive Health and Clear the Old Layout
Step 3: Check SMART health before you trust the drives. A used or older drive can look healthy in Windows and still carry reallocated sectors. If you installed smartmontools, scan for devices and read the report for each disk. Replace /dev/sdb with the device name that --scan prints.
smartctl --scan
smartctl -H /dev/sdb
smartctl -A /dev/sdb | findstr /i "Reallocated Pending Uncorrectable Power_On"
You want PASSED on the overall health line and zero on reallocated, pending, and uncorrectable sector counts. Any nonzero value on a drive you plan to trust with a mirror is a reason to swap it out now. Windows also exposes basic reliability counters without extra software. This command reads temperature, wear, and error totals where the drive reports them:
Get-PhysicalDisk | Get-StorageReliabilityCounter |
Select-Object DeviceId, Temperature, Wear, ReadErrorsTotal, WriteErrorsTotal, PowerOnHours
Save this output. It becomes your baseline, and the monitoring script later compares against the same counters. If the SMART numbers look unfamiliar, read the vendor’s attribute documentation for your exact drive model before deciding whether a nonzero count is serious, since a few attributes mean different things on different firmware.
Step 4: Clear any old partitions. A drive that came out of another PC, or one that held a previous pool, may refuse to join with CanPool set to False. Wiping it clears the old layout. Triple-check the disk number first, because Clear-Disk does not ask twice and does not care which drive you meant. Use the DeviceId values you noted in step 1.
# Replace 1 and 2 with YOUR two data disk numbers. Never use the boot disk.
Get-Disk | Format-Table Number, FriendlyName, PartitionStyle, Size
Clear-Disk -Number 1 -RemoveData -RemoveOEM -Confirm:$false
Clear-Disk -Number 2 -RemoveData -RemoveOEM -Confirm:$false
Run the step 1 command again. Both drives should now report CanPool as True. If one still reports False with the reason “In a Pool” or “Insufficient Capacity”, skip ahead to the troubleshooting section and clear the leftover pool metadata before continuing.
Steps 5 to 7: Build the Mirror in the Settings App
The graphical path suits anyone who prefers clicking over typing. It creates the same pool and mirror that the PowerShell route builds, so you can mix the two later. The wording can shift slightly between Windows 11 releases, but the flow stays the same.
Step 5: Open Storage Spaces and create a pool. Go to Settings, then System, then Storage, then Advanced storage settings, then Storage Spaces. Select Create storage pool. Windows lists every drive that is eligible. Tick the two data drives, and leave the boot disk alone. Give the pool a name you will recognize in six months, such as DataPool, and confirm.
Step 6: Create the space with a two-way mirror. After the pool exists, choose Create storage space. You will see fields for name, drive letter, file system, resiliency type, and size. Set them like this:
- Name:
Mirror(this is the virtual disk name) - Drive letter: any free letter, for example
M: - File system: NTFS. Some editions and builds also offer ReFS, which adds checksumming, but NTFS is the safe default for ordinary files.
- Resiliency type: Two-way mirror. Do not pick Simple. That option stripes data across the drives with no redundancy, and one failure destroys everything.
- Size: The maximum Windows offers for a two-way mirror, which equals the smaller drive’s usable capacity.
The size field deserves care. Storage Spaces supports thin provisioning, which means you can type a size larger than your physical capacity and the pool will warn you as it fills. That works in data centers with monitoring and spare drives on a shelf. On a home PC it invites a full pool, a stalled volume, and a confusing error. Use a fixed size that fits inside the real capacity.
Step 7: Confirm and wait for formatting. Select Create. Windows partitions the virtual disk, formats it, and mounts it at your chosen letter. A quick format finishes in seconds. Open File Explorer and you should see a new drive with roughly the capacity of one member drive, minus a small overhead for pool metadata. If the drive appears with the expected size, the mirror exists.
One small habit pays off here. Right-click the new drive, open Properties, and set a volume label such as Mirror. When you later run scripts or plug the pool into another PC, a labeled volume is easier to spot among a crowd of drives named Local Disk.
Steps 8 and 9: Verify With PowerShell and Learn the Scripted Build
Step 8: Verify the layout. The graphical page hides details that matter. PowerShell shows the resiliency type, the number of data copies, and the health of each layer. Run these three commands in an elevated terminal:
Get-StoragePool -IsPrimordial $false | Format-List FriendlyName, HealthStatus, OperationalStatus
Get-VirtualDisk | Format-List FriendlyName, ResiliencySettingName, NumberOfDataCopies, `
NumberOfColumns, ProvisioningType, HealthStatus, OperationalStatus, Size, FootprintOnPool
Get-PhysicalDisk | Where-Object Usage -eq 'AutoSelect' |
Format-Table FriendlyName, HealthStatus, OperationalStatus, Usage -AutoSize
A healthy two-way mirror prints output like the sample below. The key lines are ResiliencySettingName : Mirror and NumberOfDataCopies : 2. If you see Simple or 1, you built a stripe by mistake, so delete the space and redo step 6 before storing anything.
FriendlyName : Mirror
ResiliencySettingName : Mirror
NumberOfDataCopies : 2
NumberOfColumns : 1
ProvisioningType : Fixed
HealthStatus : Healthy
OperationalStatus : OK
Size : 3995 GB
FootprintOnPool : 7990 GB
The footprint line makes the cost of mirroring concrete. A space occupies about twice its size on the pool, because every block exists twice.
Step 9: Learn the scripted build. Everything the Settings app did can be one short script, which is how you rebuild the mirror after a fresh Windows install or on a second PC. The snippet below creates the pool, the two-way mirror, and the formatted volume. It is the core of the full project later on, so read it slowly. This version assumes you completed step 4 and your two disks show CanPool as True.
$disks = Get-PhysicalDisk -CanPool $true
if ($disks.Count -ne 2) { throw "Expected exactly 2 poolable disks, found $($disks.Count)" }
$sub = Get-StorageSubSystem -FriendlyName "Windows Storage*"
New-StoragePool -FriendlyName "DataPool" -StorageSubSystemFriendlyName $sub.FriendlyName -PhysicalDisks $disks
New-VirtualDisk -StoragePoolFriendlyName "DataPool" -FriendlyName "Mirror" `
-ResiliencySettingName Mirror -NumberOfDataCopies 2 `
-ProvisioningType Fixed -UseMaximumSize
Get-VirtualDisk -FriendlyName "Mirror" | Get-Disk |
Initialize-Disk -PartitionStyle GPT -PassThru |
New-Partition -DriveLetter M -UseMaximumSize |
Format-Volume -FileSystem NTFS -NewFileSystemLabel "Mirror" -Confirm:$false
Do not run this on top of the pool you just built in the Settings app, because the pool name and drive letter would collide. Treat it as a reference now, and use it in anger when you rebuild from scratch.
Steps 10 and 11: Prove the Data Is Safe and Tune the Power Settings
Step 10: Copy test data and verify it with hashes. Before you move your real files in, run a trial. Copy a folder of mixed files, ideally a few hundred megabytes of photos, documents, and a large video, onto the mirror. Then compare file hashes between source and copy. This catches silent corruption from a flaky cable or a controller problem before it touches irreplaceable data.
$src = "C:TestSet"
$dst = "M:TestSet"
Copy-Item $src $dst -Recurse -Force
$a = Get-ChildItem $src -Recurse -File | Get-FileHash -Algorithm SHA256
$b = Get-ChildItem $dst -Recurse -File | Get-FileHash -Algorithm SHA256
$diff = Compare-Object ($a | Select-Object -ExpandProperty Hash) ($b | Select-Object -ExpandProperty Hash)
if ($diff) { "MISMATCH" } else { "All hashes match" }
You want to see All hashes match. Any mismatch means you should stop and investigate the cables, the SATA ports, and the drive health from step 3 before trusting the volume. Once the test passes, move your real data in. For large libraries, use robocopy with the /E /COPY:DAT /R:1 /W:1 switches so timestamps survive and failures do not hang the job, then run the hash comparison again on a sample.
Step 11: Stop Windows from sleeping the drives. Desktop power plans spin down idle hard drives, and an aggressive USB or PCIe power setting can make a member briefly vanish. A momentary dropout makes Storage Spaces mark the drive as lost, then start a repair when it returns. Cut the noise by turning off disk sleep on AC power and, if any member sits behind a USB bridge, disabling selective suspend:
powercfg /change disk-timeout-ac 0
powercfg /setacvalueindex SCHEME_CURRENT 2a737441-1930-4402-8d77-b2bebba308a3 48e6b7a6-50f5-4782-a5d4-53bb8f07e226 0
powercfg /setactive SCHEME_CURRENT
Laptop users should apply the same idea to the plugged-in profile only. Keeping drives awake on battery shortens runtime, and a mirror on a laptop is rare anyway. Desktop owners can also check the BIOS for any ALPM or link power management options on SATA ports, though most boards ship sensible defaults and you can leave those alone unless you see dropouts in the event log.
Step 12: Pull a Drive on Purpose and Rebuild
Nobody trusts a mirror until they have watched one survive a failure. Do this drill while the volume holds only your test data. It takes about fifteen minutes on SSDs and longer on big hard drives, and it turns a hopeful guess into something you have seen with your own eyes.
Simulate the failure. Shut the PC down properly, unplug the SATA data cable from one mirror member (not the power, and not the boot drive), and boot Windows. Do not hot-unplug SATA drives on a board that lacks hot-swap support, since the surprise can upset the controller. Open Storage Spaces. The pool now shows a warning, the space shows as degraded, and the M: drive still opens with all your files readable. That is the entire point of RAID 1.
Get-VirtualDisk | Format-Table FriendlyName, HealthStatus, OperationalStatus
Get-PhysicalDisk | Format-Table FriendlyName, HealthStatus, OperationalStatus, Usage
# Sample degraded output
# FriendlyName HealthStatus OperationalStatus
# ------------ ------------ -----------------
# Mirror Warning {Degraded, Incomplete}
Rebuild by reconnecting. Shut down again, reattach the cable, and boot. Windows detects the returning member and starts a repair. Watch it with Get-StorageJob. If the repair does not start by itself, trigger it manually:
Repair-VirtualDisk -FriendlyName "Mirror"
Get-StorageJob | Format-Table Name, JobState, PercentComplete, BytesProcessed, BytesTotal
When the job finishes, the space returns to Healthy. You have just done the same thing you will do after a real failure, minus the replacement drive.
The Real Replacement Procedure
A genuine dead drive needs a few extra commands. Mark the failing drive as retired so Windows stops using it, add the new drive to the pool, repair, and only then remove the old one from the pool. Follow that order, because removing the old drive first can leave the pool with no spare capacity to rebuild into.
$old = Get-PhysicalDisk -FriendlyName "WD Red Plus 4TB" | Where-Object HealthStatus -ne Healthy
Set-PhysicalDisk -InputObject $old -Usage Retired
$new = Get-PhysicalDisk -CanPool $true
Add-PhysicalDisk -StoragePoolFriendlyName "DataPool" -PhysicalDisks $new
Repair-VirtualDisk -FriendlyName "Mirror"
# wait for Get-StorageJob to finish, then:
Remove-PhysicalDisk -StoragePoolFriendlyName "DataPool" -PhysicalDisks $old
Match the replacement to the old drive’s class where you can. A new drive smaller than the survivor can never hold the full mirror, and a shingled (SMR) hard drive slotted in beside a conventional one can make long rebuilds crawl. Check the replacement’s recording method on the maker’s spec sheet before you buy.
Step 13: Set Up Monitoring So You Learn About Failures Early
A mirror that fails quietly is worse than no mirror, because you keep running on one drive without knowing. Plenty of people have discovered a degraded pool months after the first member died, only when the second one followed. Monitoring closes that gap, and it costs one scheduled task.
Windows already logs Storage Spaces events in its system logs. Warnings there appear the moment a member drops out. Reading the log manually is fine for a drill but useless day to day, so the project in the next section turns it into an automated daily check that writes to the Application log and a text file.
The check looks at four things. First, the pool and virtual disk health status. Second, each physical disk’s health status. Third, any running repair jobs. Fourth, the reliability counters for temperature and error totals, compared against limits you set. If any of them cross a threshold, the script writes a warning event and, if you configure a webhook, posts a message to the chat or notification service you already use.
Decide now how a warning will reach you. A text file in a folder you never open does not count as an alert. Pick something you see daily: a phone push through a self-hosted notification service, a Slack or Teams webhook, or an email relay. The script accepts a generic JSON webhook URL and leaves the choice to you.
Complete Working Project: Build and Watch the Mirror With Two Scripts
These two scripts bundle everything above. The first, New-MirrorPool.ps1, builds the pool and volume with safety checks. The second, Check-Mirror.ps1, runs daily and reports problems. Save both in C:Scripts. Use Windows PowerShell for both, launched from an elevated terminal.
Script 1: New-MirrorPool.ps1
#Requires -RunAsAdministrator
param(
[string]$PoolName = "DataPool",
[string]$SpaceName = "Mirror",
[char] $DriveLetter = "M",
[string]$Label = "Mirror",
[switch]$Force
)
$ErrorActionPreference = "Stop"
# 1. Find candidate disks
$disks = Get-PhysicalDisk -CanPool $true
if ($disks.Count -ne 2) {
Get-PhysicalDisk | Format-Table DeviceId, FriendlyName, CanPool, CannotPoolReason
throw "Need exactly 2 poolable disks, found $($disks.Count). Clear old layouts first."
}
# 2. Refuse to mix wildly different sizes without -Force
$sizes = $disks | ForEach-Object { $_.Size }
$ratio = ($sizes | Measure-Object -Maximum).Maximum / ($sizes | Measure-Object -Minimum).Minimum
if ($ratio -gt 1.1 -and -not $Force) {
throw "Disk sizes differ by more than 10 percent. Usable space equals the smaller disk. Re-run with -Force to continue."
}
# 3. Refuse an existing pool or letter
if (Get-StoragePool -FriendlyName $PoolName -ErrorAction SilentlyContinue) { throw "Pool $PoolName already exists." }
if (Get-Volume -DriveLetter $DriveLetter -ErrorAction SilentlyContinue) { throw "Drive letter $DriveLetter is in use." }
# 4. Show what will be erased and ask for confirmation
$disks | Format-Table FriendlyName, SerialNumber, @{n='SizeGB';e={[math]::Round($_.Size/1GB)}}
if (-not $Force) {
$ans = Read-Host "These disks will be ERASED. Type YES to continue"
if ($ans -ne "YES") { throw "Cancelled." }
}
# 5. Build pool, mirror, volume
$sub = Get-StorageSubSystem -FriendlyName "Windows Storage*"
New-StoragePool -FriendlyName $PoolName -StorageSubSystemFriendlyName $sub.FriendlyName -PhysicalDisks $disks | Out-Null
New-VirtualDisk -StoragePoolFriendlyName $PoolName -FriendlyName $SpaceName `
-ResiliencySettingName Mirror -NumberOfDataCopies 2 `
-ProvisioningType Fixed -UseMaximumSize | Out-Null
Get-VirtualDisk -FriendlyName $SpaceName | Get-Disk |
Initialize-Disk -PartitionStyle GPT -PassThru |
New-Partition -DriveLetter $DriveLetter -UseMaximumSize |
Format-Volume -FileSystem NTFS -NewFileSystemLabel $Label -Confirm:$false | Out-Null
# 6. Report
Get-VirtualDisk -FriendlyName $SpaceName |
Format-List FriendlyName, ResiliencySettingName, NumberOfDataCopies, HealthStatus, OperationalStatus
Write-Host "Done. Mirror mounted at ${DriveLetter}:" -ForegroundColor Green
Script 2: Check-Mirror.ps1
#Requires -RunAsAdministrator
param(
[string]$PoolName = "DataPool",
[string]$SpaceName = "Mirror",
[string]$LogDir = "C:Scriptslogs",
[string]$WebhookUrl = "",
[int] $MaxTempC = 55,
[int] $MaxWearPct = 80
)
$problems = New-Object System.Collections.Generic.List[string]
New-Item -ItemType Directory -Path $LogDir -Force | Out-Null
$pool = Get-StoragePool -FriendlyName $PoolName -ErrorAction SilentlyContinue
if (-not $pool) { $problems.Add("Pool $PoolName not found") }
elseif ($pool.HealthStatus -ne "Healthy") { $problems.Add("Pool health: $($pool.HealthStatus)") }
$vd = Get-VirtualDisk -FriendlyName $SpaceName -ErrorAction SilentlyContinue
if (-not $vd) { $problems.Add("Space $SpaceName not found") }
else {
if ($vd.HealthStatus -ne "Healthy") { $problems.Add("Space health: $($vd.HealthStatus) / $($vd.OperationalStatus)") }
if ($vd.NumberOfDataCopies -lt 2) { $problems.Add("Space has only $($vd.NumberOfDataCopies) data copy") }
}
if ($pool) {
foreach ($pd in Get-StoragePool -FriendlyName $PoolName | Get-PhysicalDisk) {
if ($pd.HealthStatus -ne "Healthy") { $problems.Add("Disk $($pd.FriendlyName) health: $($pd.HealthStatus)") }
$rc = $pd | Get-StorageReliabilityCounter -ErrorAction SilentlyContinue
if ($rc) {
if ($rc.Temperature -and $rc.Temperature -gt $MaxTempC) { $problems.Add("Disk $($pd.FriendlyName) temp $($rc.Temperature) C") }
if ($rc.Wear -and $rc.Wear -gt $MaxWearPct) { $problems.Add("Disk $($pd.FriendlyName) wear $($rc.Wear) percent") }
if ($rc.WriteErrorsTotal -gt 0 -or $rc.ReadErrorsTotal -gt 0) {
$problems.Add("Disk $($pd.FriendlyName) errors: read $($rc.ReadErrorsTotal), write $($rc.WriteErrorsTotal)")
}
}
}
}
$jobs = Get-StorageJob | Where-Object JobState -eq "Running"
if ($jobs) { $problems.Add("Repair or rebalance running: " + (($jobs | ForEach-Object { "$($_.Name) $($_.PercentComplete)%" }) -join ", ")) }
$stamp = Get-Date -Format "yyyy-MM-dd HH:mm"
$line = if ($problems.Count -eq 0) { "$stamp OK" } else { "$stamp PROBLEM: " + ($problems -join " | ") }
Add-Content -Path (Join-Path $LogDir "mirror.log") -Value $line
if ($problems.Count -gt 0) {
if (-not [System.Diagnostics.EventLog]::SourceExists("MirrorWatch")) {
New-EventLog -LogName Application -Source "MirrorWatch"
}
Write-EventLog -LogName Application -Source "MirrorWatch" -EntryType Warning -EventId 4100 -Message $line
if ($WebhookUrl) {
$body = @{ text = "Mirror alert on $env:COMPUTERNAME : $line" } | ConvertTo-Json
Invoke-RestMethod -Uri $WebhookUrl -Method Post -ContentType "application/json" -Body $body | Out-Null
}
exit 1
}
exit 0
Schedule the Daily Check
Register the check as a task that runs at 8 a.m. every day under the SYSTEM account with highest privileges. Run this once from an elevated terminal:
$action = New-ScheduledTaskAction -Execute "powershell.exe" `
-Argument "-NoProfile -ExecutionPolicy Bypass -File C:ScriptsCheck-Mirror.ps1"
$trigger = New-ScheduledTaskTrigger -Daily -At 8:00am
$prin = New-ScheduledTaskPrincipal -UserId "SYSTEM" -LogonType ServiceAccount -RunLevel Highest
Register-ScheduledTask -TaskName "MirrorWatch" -Action $action -Trigger $trigger -Principal $prin
Start-ScheduledTask -TaskName "MirrorWatch"
Get-Content C:Scriptslogsmirror.log -Tail 3
A healthy mirror writes a line like 2026-10-31 08:00 OK. During your step 12 drill, run the task by hand while the pool is degraded and you should see a PROBLEM line plus a MirrorWatch warning in the Application log. That confirms the alert path works before you need it.
Common Pitfalls That Break or Weaken a Windows Mirror
Most mirror disasters trace back to a handful of avoidable mistakes. Here are the ones that cause the most damage, with the reason each one hurts.
- Treating the mirror as a backup. Delete a file and it vanishes from both drives in the same instant. Ransomware encrypts both copies. A mirror covers hardware failure only, so pair it with versioned backups, whether local or an encrypted cloud service.
- Choosing Simple resiliency by accident. The dropdown order in some builds puts Simple near the top. It looks fine, and it behaves like RAID 0. One failure takes the whole volume. Confirm
NumberOfDataCopiesis 2 after every build. - Ignoring a degraded warning. The mirror keeps working on one drive, so nothing feels broken. People then wait weeks to act. Treat the first warning as an emergency, because the second drive is now a single point of failure.
- Using USB-attached members. USB bridges reset, sleep, and disconnect under load. Each dropout triggers a repair and stresses the survivor. Keep members on SATA or NVMe.
- Buying both drives from one batch. Drives with the same manufacture date and workload often wear alike. Mix batches or retailers when you can.
- Putting thin provisioning on a home pool. A pool that promises more space than it owns can fill with no clear warning, and apps then fail with odd write errors. Use fixed provisioning.
- Pulling the wrong drive during a failure. Without serial numbers noted, owners yank the healthy member. Label your drives and keep the step 1 list in a note.
- Skipping the drill. A mirror you never tested is a theory. Run step 12 once and you will know exactly what failure looks like on your machine.
One more trap deserves its own mention: a motherboard that is set to RAID mode in the BIOS without you realizing it. If an earlier owner or a factory image enabled RAID mode, Windows may see your drives through a RAID driver, and some drives will not show as poolable at all. Open the BIOS and confirm the SATA mode reads AHCI before you blame Storage Spaces.
Troubleshooting: 10 Fixes for Storage Spaces Mirror Problems
When something goes wrong, work from the cheapest check to the most invasive. The table lists the ten problems readers run into most, with the likely cause and the fix. Commands assume an elevated PowerShell session.
| # | Symptom | Likely cause | Fix |
|---|---|---|---|
| 1 | Drive shows CanPool: False, reason In a Pool |
Leftover pool metadata from an earlier setup | Run Get-StoragePool, remove the old pool with Remove-StoragePool, then Clear-Disk -RemoveData -RemoveOEM |
| 2 | Reason Insufficient Capacity | Drive has unallocated space but an old partition table | Wipe with Clear-Disk, rescan with Update-HostStorageCache |
| 3 | Space shows Warning and Degraded | A member disconnected or failed | Check cables, reboot, then Repair-VirtualDisk. If the disk is dead, follow the retire and replace sequence |
| 4 | Repair never starts | Returning disk is still marked as Retired or lost | Run Set-PhysicalDisk -Usage AutoSelect on it, then repair |
| 5 | Repair job stuck at one percent | Failing sectors on the surviving drive, or a sleeping USB bridge | Check SMART on the survivor, copy data off first, replace if errors show |
| 6 | Volume is read-only | Pool or space switched to read-only after errors | Fix the underlying fault, then run Set-StoragePool -IsReadOnly $false and reconnect the space with Connect-VirtualDisk |
| 7 | Mirror missing after a Windows reinstall | Pool exists but is not mounted | Open Storage Spaces and import the pool, then bring the disk online with Set-Disk -IsOffline $false |
| 8 | Drive letter vanishes after reboot | Virtual disk is offline or letter conflict | Run Get-VirtualDisk | Get-Disk | Set-Disk -IsOffline $false and reassign with Set-Partition -NewDriveLetter |
| 9 | Writes very slow after replacing a drive | SMR hard drive during sustained writes, or a repair running | Wait for Get-StorageJob to finish, and prefer CMR drives for mirrors |
| 10 | Blue screen after switching SATA mode in BIOS | RAID driver not loaded for the new mode | Switch back to the original mode, boot, then plan a clean change with the driver injected |
Two diagnostics unlock most of the rest. First, read the Storage Spaces event log, which names the exact disk and error. Second, run Get-StorageReliabilityCounter on every member and compare against your step 3 baseline. A jump in error totals points at a cable or a dying drive before Windows declares anything unhealthy.
If a disk reports unrecognized metadata or the pool refuses to import, do not format anything in a hurry. Power down, test each drive alone in another PC, and copy off whatever you can read. Pool metadata lives on the member drives, and a good drive from a damaged pool often still holds your files in readable form.
Advanced Tips for Power Users
Add a Hot Spare
If you have a third drive and a slot to spare, add it as a hot spare. Windows will automatically pull it into the mirror when a member fails, and the repair starts without you. Use Add-PhysicalDisk -StoragePoolFriendlyName "DataPool" -PhysicalDisks $third -Usage HotSpare. This narrows the window in which the mirror runs unprotected, which matters most on big hard drives.
Rebalance After Changes and Consider ReFS
After you add or replace drives, run Optimize-StoragePool -FriendlyName "DataPool" to rebalance data. If your volume uses ReFS, which some editions offer, Windows can also verify checksums in the background and repair bad blocks from the good copy. That self-repair behavior is the main reason to pick ReFS for a mirror of important files. Check that your edition exposes it before you plan around it, and stay on NTFS if it does not.
Encrypt the Mirror With BitLocker
On Pro and above you can turn on BitLocker for the mirror volume from its right-click menu. Encryption sits on top of the mirror, so redundancy and security stack neatly. Save the recovery key to your account and print or store a copy offline. Losing both the key and a drive is the one combination no mirror can fix.
Beyond those three, keep an eye on three habits. Update storage firmware when the maker releases fixes, since drive firmware bugs are a known cause of surprise dropouts. Replace members on a schedule rather than at death, because drives that have served for several years carry rising odds of failure. And export a copy of your Get-PhysicalDisk serial list every time you change the setup, so the next rebuild starts with facts instead of guesses.
Finally, remember the escape hatch. A Storage Spaces pool travels. If your PC dies, put both drives in another Windows 11 machine, open Storage Spaces, and import the pool. Nothing about the layout is tied to your old motherboard, which is the best argument for choosing this method over firmware RAID in a home setup.
Frequently Asked Questions
Does Windows 11 Home support RAID 1?
Yes, through Storage Spaces. The two-way mirror option works in Home, Pro, and Enterprise. The older mirrored volume feature needs Pro or above, so Home users should use Storage Spaces.
Can I mirror my C: boot drive with Storage Spaces?
No. Storage Spaces volumes cannot host the Windows system partition. To mirror the boot drive you need firmware RAID or a hardware controller configured before you install Windows.
Can I use two drives of different sizes?
Yes, but usable capacity equals the smaller drive in a two-drive pool, and the extra space on the larger one sits idle. Matched sizes waste nothing.
Is RAID 1 faster than a single drive?
Reads can improve because either copy can serve a request. Writes go to both drives, so they run at roughly the pace of the slower one. Expect no dramatic gain, and choose a mirror for resilience.
Do I still need a backup if I run a mirror?
Yes. Deleted files, malware, corruption, fire, and theft hit both drives at once. Keep at least one separate, ideally offsite, copy.
What happens if one drive fails?
The volume stays online and readable from the surviving drive, and Windows reports a degraded state. Replace the failed drive, run a repair, and the mirror returns to healthy once the resync completes.
Can I move the mirror to a new PC?
Yes. Connect both drives to another Windows 11 computer, open Storage Spaces, and import the pool. Make sure both drives travel together, and avoid writing to the pool from two machines at once.
Should I use Storage Spaces or my motherboard’s RAID?
Use Storage Spaces for data volumes, because it needs no BIOS change and survives a board swap. Choose firmware RAID only when you must mirror the drive Windows boots from.