Windows Blue Screen of Death (BSOD): Complete Troubleshooting Guide for All Stop Codes
Fix Windows Blue Screen errors including MEMORY_MANAGEMENT, SYSTEM_SERVICE_EXCEPTION, VIDEO_TDR_FAILURE & more. Step-by-step repair guide with real commands.
- Most BSODs are caused by faulty or incompatible drivers (especially GPU drivers like nvlddmkm.sys), corrupted system files, bad RAM, or failing storage devices.
- Stop codes like 0xc00021a, UNMOUNTABLE_BOOT_VOLUME, and NTFS.SYS point to boot/disk corruption; MEMORY_MANAGEMENT and PFN_LIST_CORRUPT point to RAM issues; VIDEO_TDR_FAILURE and SYSTEM_SERVICE_EXCEPTION often point to driver conflicts.
- Quick fixes: Boot into Safe Mode, run 'sfc /scannow' and 'DISM /RestoreHealth', update or roll back recent drivers, run Windows Memory Diagnostic, and check Event Viewer for the faulting module before reinstalling Windows.
| Method | When to Use | Time | Risk |
|---|---|---|---|
| SFC + DISM Repair | Corrupted system files (ntfs.sys, wdf_violation, 0xc00021a) | 15-30 min | Low |
| Driver Rollback / Update | VIDEO_TDR_FAILURE, nvlddmkm.sys, SYSTEM_SERVICE_EXCEPTION | 10-20 min | Low |
| Windows Memory Diagnostic / MemTest86 | MEMORY_MANAGEMENT, PFN_LIST_CORRUPT, UNEXPECTED_KERNEL_MODE_TRAP | 1-8 hrs | None |
| Startup Repair (WinRE) | BSOD loop at startup, UNMOUNTABLE_BOOT_VOLUME, 0xc00021a | 15-40 min | Low |
| CHKDSK on Boot Volume | ntfs.sys, UNMOUNTABLE_BOOT_VOLUME, disk I/O errors | 30-90 min | Low |
| System Restore | BSOD after recent update or software install | 20-40 min | Low-Medium |
| Clean Driver Install (DDU) | Persistent GPU BSOD, nvlddmkm.sys, VIDEO_TDR_FAILURE | 30-45 min | Low |
| Windows Reset / Reinstall | All other fixes failed, recurring loop, severe corruption | 1-3 hrs | High (data loss possible) |
Understanding the Windows Blue Screen of Death (BSOD)
A Blue Screen of Death (BSOD) — technically called a Stop Error — occurs when Windows encounters a critical kernel-level fault it cannot recover from. The system halts to prevent data corruption and dumps kernel memory to disk (the minidump or full memory dump), then optionally restarts. Every BSOD displays a stop code (e.g., MEMORY_MANAGEMENT, SYSTEM_SERVICE_EXCEPTION, VIDEO_TDR_FAILURE) and sometimes a QR code or faulting filename (e.g., nvlddmkm.sys, ntfs.sys).
Modern Windows 10/11 BSODs also display an emoticon face and a brief description. You can capture the stop code and faulting module from the blue screen itself, from Event Viewer, or from the minidump file.
Step 1: Capture the Stop Code and Faulting Module
From the Blue Screen: Note the exact stop code (e.g., KERNEL_SECURITY_CHECK_FAILURE) and any filename shown (e.g., nvlddmkm.sys). Photograph the screen if necessary.
From Event Viewer:
- Press
Win + X→ Event Viewer - Navigate to Windows Logs → System
- Filter by Event ID 41 (unexpected shutdown/crash) and 1001 (BugCheck)
- The BugCheck event shows the stop code in hexadecimal and the faulting address.
From Minidump Files:
Minidumps are stored at C:\Windows\Minidump\. Use WinDbg (Windows Debugger) or the free WhoCrashed tool to analyze them. WinDbg command after opening a dump:
!analyze -v
This reveals the faulting driver, stack trace, and exact cause.
Step 2: Identify Your Specific Stop Code
MEMORY_MANAGEMENT / STOP CODE MEMORY MANAGEMENT / PFN_LIST_CORRUPT
These indicate RAM-level issues — bad memory modules, incorrect XMP/EXPO profiles, or memory controller faults.
- Action: Run Windows Memory Diagnostic or MemTest86 (see code block below).
- Reseat RAM sticks. Test one stick at a time.
- Disable XMP/EXPO in BIOS and run at stock speeds.
SYSTEM_SERVICE_EXCEPTION / KERNEL_SECURITY_CHECK_FAILURE / UNEXPECTED_KERNEL_MODE_TRAP
These usually point to a kernel driver crash — antivirus, GPU drivers, VPN software, or corrupted system files.
- Action: Boot Safe Mode, uninstall recently added software/drivers, run SFC and DISM.
- Check the faulting module name in Event Viewer or WinDbg.
VIDEO_TDR_FAILURE (nvlddmkm.sys)
nvlddmkm.sys is the NVIDIA kernel-mode driver. TDR (Timeout Detection and Recovery) fires when the GPU fails to respond within the timeout window.
- Action: Use DDU (Display Driver Uninstaller) in Safe Mode → clean install latest NVIDIA drivers from nvidia.com.
- Underclock GPU memory slightly if overclocked.
- Check GPU temperatures under load (MSI Afterburner, HWiNFO64).
NTFS.SYS
Indicates file system corruption on an NTFS volume.
- Action: Run
chkdsk C: /f /rfrom elevated CMD or WinRE. - Run SFC and DISM.
- If drive is failing (check S.M.A.R.T. data with CrystalDiskInfo), replace the drive.
0xc00021a (Fatal System Error)
This critical stop code means the Windows Session Manager (smss.exe) or Win32 subsystem (csrss.exe) terminated unexpectedly. Common after bad Windows updates or system file corruption.
- Action: Boot WinRE → Startup Repair → System Restore.
- If those fail, run
sfc /scannowoffline from WinRE command prompt. - Last resort: In-place upgrade repair using Windows ISO.
UNMOUNTABLE_BOOT_VOLUME
Windows cannot mount the boot partition — usually disk corruption, a failing drive, or missing/corrupt boot files.
- Action: Boot from Windows USB → Troubleshoot → Command Prompt → run
chkdsk C: /f /randbootrec /fixmbr,bootrec /fixboot,bootrec /rebuildbcd.
WDF_VIOLATION
A Windows Driver Framework violation — a buggy WDF-based driver caused a fatal assertion.
- Action: Identify the faulting driver via WinDbg
!analyze -v. Update or remove the offending driver. Common culprits: USB 3.0 controllers, Bluetooth adapters, third-party input devices.
WINDOWS BLUE SCREEN LOOP (Restart Loop)
If Windows restarts immediately into another BSOD, you need to break the loop first:
- Hard power off three times to trigger WinRE (Automatic Repair mode).
- Or boot from a Windows USB installer → Repair your computer.
- In WinRE: Troubleshoot → Advanced Options → Startup Settings → Disable automatic restart on failure (option 9) to see the stop code.
Step 3: Core Repair Commands (Run as Administrator)
System File Checker:
sfc /scannow
This scans and repairs protected system files. Requires a restart in some cases. If it reports it couldn't fix files, run DISM first.
DISM Health Restore:
DISM /Online /Cleanup-Image /CheckHealth
DISM /Online /Cleanup-Image /ScanHealth
DISM /Online /Cleanup-Image /RestoreHealth
DISM repairs the Windows Component Store that SFC depends on. Run DISM before SFC for best results.
CHKDSK (run on reboot):
chkdsk C: /f /r /x
Schedules a disk check on the next reboot. The /r flag locates bad sectors and recovers readable data. This can take 1-2 hours on large drives.
Check for Windows Updates: Outdated drivers shipped via Windows Update can cause BSODs — keep Windows fully updated.
wuauclt /detectnow
Or use Settings → Windows Update → Check for Updates.
Step 4: Driver-Specific Fixes
Rolling Back a Driver:
- Press
Win + X→ Device Manager - Find the suspicious device (Display Adapters for GPU issues)
- Right-click → Properties → Driver tab → Roll Back Driver
Clean GPU Driver Install with DDU:
- Download DDU from guru3d.com
- Boot into Safe Mode (Win + I → Recovery → Advanced Startup → Restart Now → Troubleshoot → Advanced → Startup Settings → Safe Mode)
- Run DDU → Clean and Restart
- Install fresh drivers from nvidia.com or amd.com
Disable Driver Signature Enforcement (for testing): In WinRE Startup Settings, press F7. This lets Windows load unsigned/modified drivers for diagnostic purposes — revert after testing.
Step 5: Advanced — Analyze Dump Files with WinDbg
Install WinDbg from the Microsoft Store or Windows SDK. Open a minidump:
- File → Open Crash Dump → browse to
C:\Windows\Minidump\*.dmp - Set symbol path:
.sympath srv*c:\symbols*https://msdl.microsoft.com/download/symbols - Run:
!analyze -v
The output will show the MODULE_NAME, FAULTING_MODULE, STACK_TEXT, and often a plain-English description of the likely cause.
Step 6: BIOS/Hardware Checks
- Update BIOS/UEFI firmware — motherboard vendors regularly release fixes for memory controller and PCIe compatibility bugs.
- Check temperatures — CPU/GPU thermal throttling or overheating can cause random kernel panics. Use HWiNFO64 or Core Temp.
- Reseat components — GPU, RAM, and storage cables. A loose GPU can cause nvlddmkm.sys BSODs.
- Test with minimal hardware — remove non-essential cards and USB devices to isolate the faulting component.
- Check power supply — an underpowered or failing PSU causes random shutdowns and BSODs under load.
Step 7: Last Resort — Windows Repair Install
If all else fails, perform an in-place upgrade repair:
- Download Windows 11 or Windows 10 ISO from microsoft.com
- Mount the ISO and run
setup.exe - Choose Upgrade this PC now → Keep personal files and apps
This reinstalls the OS kernel and system files without erasing user data. It is more thorough than SFC/DISM and less destructive than a full reset.
Frequently Asked Questions
# ============================================================
# Windows BSOD Diagnostic & Repair Script
# Run as Administrator in PowerShell or CMD
# ============================================================
# --- 1. Get Recent BSOD Events from Event Viewer ---
Write-Host "=== Recent BugCheck / BSOD Events ==="
Get-WinEvent -FilterHashtable @{LogName='System'; Id=1001} -MaxEvents 10 |
Select-Object TimeCreated, Message | Format-List
# --- 2. List Minidump Files ---
Write-Host "`n=== Minidump Files ==="
Get-ChildItem "C:\Windows\Minidump" -Filter "*.dmp" -ErrorAction SilentlyContinue |
Sort-Object LastWriteTime -Descending |
Select-Object Name, LastWriteTime, Length | Format-Table
# --- 3. Run System File Checker ---
Write-Host "`n=== Running SFC (System File Checker) ==="
sfc /scannow
# --- 4. Run DISM to Repair Windows Component Store ---
Write-Host "`n=== Running DISM RestoreHealth ==="
DISM /Online /Cleanup-Image /RestoreHealth
# --- 5. Schedule CHKDSK on Next Reboot ---
Write-Host "`n=== Scheduling CHKDSK on C: for next reboot ==="
# Answer 'Y' when prompted
echo Y | chkdsk C: /f /r /x
# --- 6. Check RAM with Windows Memory Diagnostic (runs on reboot) ---
Write-Host "`n=== Scheduling Windows Memory Diagnostic ==="
# Uncomment to run:
# mdsched.exe
# --- 7. Export System Info for Analysis ---
Write-Host "`n=== Exporting System Info ==="
msinfo32 /nfo "$env:USERPROFILE\Desktop\SystemInfo.nfo"
Write-Host "System info saved to Desktop\SystemInfo.nfo"
# --- 8. Check Driver Verifier Status ---
Write-Host "`n=== Driver Verifier Status ==="
verifier /query
# --- 9. List Recently Installed Drivers (last 30 days) ---
Write-Host "`n=== Recently Installed Drivers ==="
Get-WinEvent -FilterHashtable @{LogName='System'; Id=7045} -MaxEvents 20 -ErrorAction SilentlyContinue |
Select-Object TimeCreated, Message | Format-List
# --- 10. Enable Driver Verifier on All Third-Party Drivers (Advanced, causes BSOD on bad driver) ---
# WARNING: Only enable this if you want to identify a specific bad driver.
# System will BSOD at boot if a bad driver is found, revealing the culprit.
# Disable with: verifier /reset
# verifier /standard /all
# --- 11. Check GPU Driver Info ---
Write-Host "`n=== GPU / Display Driver Info ==="
Get-WmiObject Win32_VideoController | Select-Object Name, DriverVersion, Status | Format-Table
# --- 12. RAM Info ---
Write-Host "`n=== Installed RAM Modules ==="
Get-WmiObject Win32_PhysicalMemory |
Select-Object BankLabel, Capacity, Speed, Manufacturer |
Format-Table
Write-Host "`n=== Diagnostic Complete. Check Event Viewer and Minidump files for BSOD details. ==="
# --- WinDbg Quick Reference (run these inside WinDbg after opening a .dmp file) ---
# .sympath srv*C:\Symbols*https://msdl.microsoft.com/download/symbols
# .reload
# !analyze -v
# lmvm <module_name> ; get module info
# !thread ; show crashing thread
# kv ; show stack trace
# !pool <address> ; check pool corruption (for memory BSODs)Error Medic Editorial
The Error Medic Editorial team consists of senior DevOps engineers, SREs, and Windows systems administrators with 10+ years of experience diagnosing kernel crashes, BSOD stop codes, and enterprise Windows infrastructure failures. We specialize in translating complex low-level error analysis into actionable troubleshooting guides for developers and IT professionals.
Sources
- https://learn.microsoft.com/en-us/windows-hardware/drivers/debugger/analyzing-a-kernel-mode-dump-file-with-windbg
- https://learn.microsoft.com/en-us/windows/client-management/stop-error-question-answer
- https://support.microsoft.com/en-us/windows/fix-blue-screen-errors-in-windows-4d36b9c4-b5f8-4f0e-a395-3b12e9ec2f41
- https://learn.microsoft.com/en-us/windows-hardware/drivers/devtest/driver-verifier
- https://stackoverflow.com/questions/tagged/windbg
- https://github.com/nicehash/NiceHashQuickMiner/issues/185