RousselTMLEARNING

Article · Windows administration: from discovery to expertise

Disks, volumes, Storage Spaces and RAID

1. Disks and volumes #

Preparing a disk.

Initialize, partition, format #

A new disk is initialized as GPT (recommended, required beyond 2 TB and for UEFI) or MBR (legacy). Partitions are created, formatted with a file system and mounted on a letter or folder.

Get-Disk | Format-Table Number, FriendlyName, Size, PartitionStyle, OperationalStatus
Initialize-Disk -Number 1 -PartitionStyle GPT
New-Partition -DiskNumber 1 -UseMaximumSize -DriveLetter D |
    Format-Volume -FileSystem NTFS -NewFileSystemLabel Data -AllocationUnitSize 4096 -Confirm:$false
Get-Volume ; Get-PSDrive -PSProvider FileSystem
Resize-Partition -DriveLetter D -Size (Get-PartitionSupportedSize -DriveLetter D).SizeMax   # étendre après agrandissement du disque
diskpart
DISKPART> list disk
DISKPART> select disk 1
DISKPART> clean                 # efface la table de partitions : vérifiez le numéro !
DISKPART> convert gpt
DISKPART> create partition primary
DISKPART> format fs=ntfs quick label=Data
DISKPART> assign letter=D
Common mistake: Running clean or Clear-Disk on the wrong disk. Check the number with Get-Disk (size, model, serial number) right before; a system or data disk is not recoverable afterwards.

NTFS or ReFS? #

CriterionNTFSReFS
Usesystem, files, general purposeHyper-V, Storage Spaces Direct, backups, large volumes
Windows bootyesno
Integrityjournaling, chkdskchecksums, automatic repair with mirror
Featuresquotas, compression, EFS, deduplicationblock cloning (fast VHDX), deduplication

2. Redundancy: Storage Spaces and RAID #

Protecting data against a disk failure.

Storage Spaces #

Storage Spaces

Storage Spaces is Windows’ modern software RAID. Disks form a pool; virtual disks are created in it with a chosen resiliency. The old “dynamic disks” (mirror, RAID 5 in Disk Management) are deprecated in favor of Storage Spaces.

ResiliencyRAID equivalentMin. disksUsable capacityFailures tolerated
SimpleRAID 01100 %0
Two-way mirrorRAID 1 / 10250 %1
Three-way mirror3-copy RAID 1533 %2
ParityRAID 53≈ (N−1)/N1
Dual parityRAID 67≈ (N−2)/N2
Get-PhysicalDisk -CanPool $true
New-StoragePool -FriendlyName Pool1 -StorageSubSystemFriendlyName 'Windows Storage*' -PhysicalDisks (Get-PhysicalDisk -CanPool $true)
New-VirtualDisk -StoragePoolFriendlyName Pool1 -FriendlyName Miroir -ResiliencySettingName Mirror -NumberOfDataCopies 2 -UseMaximumSize -ProvisioningType Fixed
Get-VirtualDisk Miroir | Get-Disk | Initialize-Disk -PartitionStyle GPT -PassThru |
    New-Partition -UseMaximumSize -DriveLetter E | Format-Volume -FileSystem ReFS -NewFileSystemLabel Miroir
Get-StoragePool Pool1 | Get-PhysicalDisk | Select-Object FriendlyName, HealthStatus, Usage
Repair-VirtualDisk -FriendlyName Miroir             # après remplacement d'un disque
Good to know: Parity has heavy write penalties: keep it for archives and backups, and use mirror for virtual machines and databases. RAID level principles are detailed in the Linux course. Storage Spaces Direct (Datacenter edition) extends this model to several clustered servers (hyperconvergence).

Hardware RAID #

A hardware RAID controller presents Windows a single, already redundant disk; it is managed with the vendor’s tool (iDRAC, iLO, MegaRAID). Do not combine hardware RAID and Storage Spaces on the same disks: Storage Spaces wants disks presented as is (HBA or JBOD mode).

3. Protecting and optimizing data #

Snapshots, quotas, deduplication.

Shadow copies, quotas and deduplication #

# Clichés instantanés (VSS) : versions précédentes des fichiers d'un partage
vssadmin add shadowstorage /for=D: /on=D: /maxsize=10%
vssadmin create shadow /for=D:          # sur un serveur ; planifiez-les deux fois par jour
vssadmin list shadows

# Quotas et filtrage de fichiers (rôle FSRM)
Install-WindowsFeature FS-Resource-Manager -IncludeManagementTools
New-FsrmQuota -Path D:\Data\Users -Size 20GB -Description 'Dossiers personnels'

# Déduplication des données (fichiers, VDI, sauvegardes)
Install-WindowsFeature FS-Data-Deduplication
Enable-DedupVolume -Volume D: -UsageType Default ; Get-DedupStatus
Common mistake: Treating shadow copies or RAID as a backup. They are on the same server, often on the same volume: ransomware, a controller failure or a fire takes them away. See backup, Hyper-V and troubleshooting.

Commands to know #

ActionCommand
List disksGet-Disk
Initialize as GPTInitialize-Disk -Number 1 -PartitionStyle GPT
Create and format a volumeNew-Partition -DiskNumber 1 -UseMaximumSize -AssignDriveLetter | Format-Volume -FileSystem NTFS
Extend a volumeResize-Partition -DriveLetter D -Size 200GB
Create a poolNew-StoragePool -FriendlyName Pool1 -StorageSubSystemFriendlyName 'Windows Storage*' -PhysicalDisks (Get-PhysicalDisk -CanPool $true)
Virtual disk healthGet-VirtualDisk | Select-Object FriendlyName, ResiliencySettingName, HealthStatus
Check a volumeRepair-Volume -DriveLetter D -Scan
Free spaceGet-Volume | Select-Object DriveLetter, SizeRemaining, Size

📄 Windows storage: disks, volumes, Storage Spaces and RAID →

My progress

  • ⏱ Estimated time : ≈ 7 min

Sign in to track your progress and take notes. Sign in

💬 Questions about this lesson

No questions yet: be the first to ask for help or share your configuration.

Ask a question about this lesson →

Recommended Articles

Group Policy (GPO): configuring the estate from Active Directory

Design and troubleshoot Group Policy: computer and user configuration, OU linking, LSDOU order, i...

Services, scheduled tasks, event logs and performance

Control Windows services and their recovery, automate with Task Scheduler, use event logs with Ge...

Azure storage: storage accounts, Blob, Files, disks and redundancy

Store data on Azure: storage accounts, Blob (hot, cool, archive tiers, lifecycle), Files, Queue a...

Linux administration best practices

Checklist for administering Linux servers: accounts and sudo, SSH, updates, systemd services, sto...

Backup, monitoring and troubleshooting of a Linux server

Operate a Linux server day to day: 3-2-1 backup strategy with rsync, tar, LVM snapshots and resti...

Processes, memory and performance: monitoring and troubleshooting a Linux server

Understand and control Linux processes (ps, top, signals, nice, jobs), interpret load, memory and...

Linux server security and hardening

Harden a Linux server: least privilege, updates, secure SSH, firewall, fail2ban, SELinux and AppA...

Google Cloud storage: Cloud Storage, persistent disks and Filestore

Store data on Google Cloud: Cloud Storage (classes, regional, dual-region and multi-region locati...

Networking on Linux: configuration, diagnosis, firewall and SSH

Configure and troubleshoot Linux networking: ip, ss, netplan and NetworkManager, DNS, layered dia...

Support us

♥ SUPPORT US

Support RousselTM Learning

Courses, articles, labs and certificates stay free with no intrusive ads. A voluntary contribution, of any amount you choose, pays for hosting, lab environments and new content.

Contribute with PayPal Any amount · card or PayPal accountLearn more
QR code PayPal
Or scan this QR code with your phone

Thank you, every contribution counts!