When a repair install of Windows 11 fails, the operating system does not always display a clear error message. Instead, it logs detailed failure information in a file named SetupErr.log. This log file records every error, warning, and status code generated during the setup process. Without reading this file, you may waste hours guessing why the repair stopped at 23 percent or why the system rolled back to the previous build. This article explains where to find SetupErr.log, how to interpret its error codes and timestamps, and what each common failure entry means for your system. By the end, you will be able to identify hardware conflicts, corrupted system files, and driver mismatches directly from the log.
Key Takeaways: Diagnosing Repair Install Failures with SetupErr.log
- Location of SetupErr.log: Found in C:\$Windows.~BT\Sources\Panther or C:\Windows\Panther after a rollback.
- Error code format: Look for 0x8007xxxx, 0x800Fxxxx, or 0x803Fxxxx entries that point to specific failure categories.
- Timestamp correlation: Match log timestamps with the percentage progress displayed during the installation to isolate the failing phase.
Why a Repair Install Fails and How SetupErr.log Captures the Cause
A repair install, also called an in-place upgrade, uses Windows Setup to replace all system files while keeping your apps and personal data intact. The process runs through multiple phases: copying files, expanding the Windows image, installing features, and finalizing configuration. If any phase encounters a blocking error, Setup writes the details to SetupErr.log. The log is a plain-text file that records every error condition with a timestamp, an error code, and a brief description.
The most common root causes of a failed repair install include incompatible third-party drivers, corrupted system files that cannot be replaced, insufficient disk space on the system partition, and antivirus software that blocks file operations. SetupErr.log captures the exact point of failure, which allows you to target the real problem instead of running generic troubleshooting steps.
Steps to Locate and Open SetupErr.log on Windows 11
- Open File Explorer and enable viewing of hidden files
In any File Explorer window, click the View menu on the toolbar, then select Show and check Hidden items. This step is required because the $Windows.~BT folder is hidden by default. - Navigate to the $Windows.~BT folder
In the address bar, type C:\$Windows.~BT and press Enter. If you do not see this folder, the repair install may have been fully rolled back. In that case, check C:\Windows\Panther instead. - Open the Sources folder
Double-click the Sources folder inside $Windows.~BT, then open the Panther folder. This subfolder contains all setup log files. - Locate SetupErr.log
Find the file named SetupErr.log. If it does not exist, look for SetupAct.log or setuperr.log in lowercase. Right-click the file and select Open with Notepad. - Open SetupErr.log from Windows\Panther if the folder is missing
If $Windows.~BT is absent, go to C:\Windows\Panther. Open the file named setuperr.log. This log persists even after a rollback and contains errors from the last setup attempt.
How to Interpret the Entries in SetupErr.log
Each line in SetupErr.log follows a consistent format. A typical entry looks like this:
2025-03-20 14:32:15, Error [0x800F081F] CBS: Failed to resolve package Microsoft-Windows-MediaPlayer-Package~... from pending CBS transaction
The timestamp tells you when the error occurred. The bracketed hex code is the error identifier. The text after the colon describes the component that failed. To diagnose the failure, focus on three elements: the error code, the component name, and the phase indicator if present.
Error Code Categories in SetupErr.log
Error codes in SetupErr.log fall into three main ranges. Code 0x8007xxxx indicates a general Windows update or servicing failure, often caused by a corrupted Component-Based Servicing component. Code 0x800Fxxxx points to a missing or incompatible driver or a failed CBS transaction. Code 0x803Fxxxx signals activation or licensing issues that can block the repair install from proceeding.
Phase Indicators and What They Mean
Setup logs include phase markers such as PREPARE, COPY, EXPAND, INSTALL, and FINALIZE. An error logged during the PREPARE phase usually points to a problem with the existing system state, such as a corrupted servicing stack. An error during the COPY or EXPAND phase often indicates a damaged installation media or insufficient disk space. An error during the INSTALL phase suggests a driver or service that cannot be updated.
Common Error Entries and Their Fixes
The entry 0x800F081F CBS: Failed to resolve package means the Component-Based Servicing store has a corrupted package. Run the DISM tool with the RestoreHealth option from an elevated command prompt. The entry 0x80070002 The system cannot find the file specified indicates that a required file is missing from the installation media. Redownload the Windows 11 ISO and create a new installation medium. The entry 0x803F0001 Activation: The product key is invalid means the system cannot verify your Windows license. Enter a valid product key or reinstall using a genuine ISO.
When the Log Points to a Specific Driver or Service
Some SetupErr.log entries name a specific driver file or service. For example, Error [0x800F0217] Driver driver\oem123.inf failed to install tells you exactly which driver caused the failure. To resolve this, disable the driver before attempting the repair install again. Open Device Manager, locate the device associated with the .inf file, right-click it, and select Disable device. After the repair install completes, re-enable the driver and update it from the manufacturer website.
If SetupErr.log Is Empty or Missing
An empty SetupErr.log file means that no errors were recorded during the setup process. In this case, the failure may be caused by a hardware issue such as a failing hard drive or insufficient RAM. Run the Windows Memory Diagnostic tool and check the system disk for bad sectors using the chkdsk command. If the log file is completely missing, the setup process may have failed before it initialized the logging subsystem. Ensure you have at least 20 GB of free space on the system drive and that your Windows account has full administrator privileges before running the repair install again.
Common Issues: Repair Install Still Fails After Reading SetupErr.log
Error Code 0x800F0830 After Driver Disable
This error indicates that a critical system driver is still blocking the installation. Boot into Safe Mode with Networking and run the repair install from there. Safe Mode loads only essential drivers, which often bypasses the conflict.
SetupErr.log Shows Multiple CBS Errors
Multiple Component-Based Servicing errors suggest a deeply corrupted system image. Run the DISM command with the Cleanup-Image parameter and the StartComponentCleanup switch. Then run sfc /scannow to repair system files. After these steps, attempt the repair install again.
Error 0x80070070 Disk Space Insufficient
Even if you have free space, the repair install requires temporary space equal to the size of the Windows image. Clear the temporary files using Disk Cleanup and select the Clean up system files option. Remove any non-essential programs and move personal files to an external drive to free at least 30 GB.
| Item | SetupErr.log Entry | User Action |
|---|---|---|
| Error code pattern | 0x800F081F CBS failure | Run DISM /Online /Cleanup-Image /RestoreHealth |
| Error code pattern | 0x80070002 missing file | Redownload installation media |
| Error code pattern | 0x803F0001 activation | Enter a valid product key |
| Phase marker | PREPARE | Check servicing stack health |
| Phase marker | INSTALL | Disable conflicting drivers |
You can now open SetupErr.log after any failed repair install and quickly identify whether the problem is a corrupted CBS store, a missing file, or a driver conflict. The next time you run a repair install, keep SetupErr.log open in Notepad and refresh it periodically while setup runs. For advanced diagnostics, filter the log using the findstr command: findstr /i "error" C:\$Windows.~BT\Sources\Panther\SetupErr.log to display only error lines.