Issue
Windows Recovery Environment can be present on disk but disabled, registered to the wrong location, or disconnected from the Windows loader's recovery BCD object. Settings Advanced startup, Shift+Restart, automatic repair, or the boot error screen may then fail to open the built-in recovery tools. Because Startup Settings is launched from WinRE, the same registration failure can remove access to Safe Mode selection even though Safe Mode itself is not damaged.
This writeup repairs registration only when a valid existing winre.wim, its owning Windows installation, the intended recovery partition, and a readable BCD store have been proven. It does not create, resize, delete, format, or reconstruct a recovery partition, and it does not obtain winre.wim from another computer.
Searchable Windows error codes and exact messages
There is no numeric Windows code that uniquely means WinRE is disabled or misregistered. Search the complete message and reagentc /info output.
| Displayed identifier | Windows name or exact message | When it can apply |
|---|---|---|
Windows RE status: Disabled | Output from reagentc /info | Direct evidence that built-in WinRE is not enabled for that Windows installation. It does not prove that a valid image is available. |
Blank Windows RE location | Output from reagentc /info | The recovery image is not registered to a location. Confirm whether a valid existing image is staged locally or stored on a recovery partition. |
| No numeric code | REAGENTC.EXE: The Windows RE image was not found. | REAgentC could not locate a usable image at the default or specified location. Stop if no valid existing winre.wim can be proven. |
| No numeric code | REAGENTC.EXE: Unable to update Boot Configuration Data. | The recovery image may exist, but REAgentC could not update the BCD. Inspect the explicit store before changing registration again. |
| No numeric code | Could not find the recovery environment. Insert your Windows installation or recovery media, and restart your PC with the media. | Windows cannot launch its registered recovery environment. External Windows media is the immediate safe fallback. |
0xc000000f | The Boot Configuration Data for your PC is missing or contains errors | Can prevent Windows Boot Manager from reaching the recovery object. Give the code weight only when the screen names \Boot\BCD, \BCD, \EFI\Microsoft\Boot\BCD, or the recovery path. |
0xc0000034 | The Boot Configuration Data file is missing some required information | Can accompany a missing recovery sequence or damaged system store, but it is not WinRE-specific. |
0xc0000098 | The Boot Configuration Data file doesn't contain valid information for an operating system | Can apply when the displayed file is \BCD. The same status can identify an unrelated missing or incompatible driver, so record the complete named file. |
0xc0000225 | STATUS_NOT_FOUND / A required device isn't connected or can't be accessed | A recovery device, boot object, or other referenced device cannot be resolved. |
0xc000000e | STATUS_NO_SUCH_DEVICE | BCD references a device that does not exist. This requires BCD/device-path diagnosis rather than blind REAgentC repetition. |
0xc0000017 | STATUS_NO_MEMORY / not enough memory to create a RAM-disk device | WinRE could be registered correctly but unable to create its RAM disk. Route to memory and BCD bad-memory-list diagnostics; do not treat it as a registration failure. |
Event ID 4502 | Windows Recovery Environment servicing failed. | When the event also records ErrorPhase 2, Microsoft associates it with WinRE servicing/free-space work. This writeup performs no partition resizing. |
0x80070643 | ERROR_INSTALL_FAILURE during a WinRE update | An update failure is not proof that registration is wrong. Follow the update KB and partition-space evidence; do not use this article based on the code alone. |
| No numeric code | Startup Settings is absent, Shift+Restart returns to Windows, or Advanced startup returns to firmware | Searchable symptoms. Confirm WinRE status, image, BCD, and path before attributing them to BP-035. |
Applies when
Use this procedure when reagentc /info shows Disabled, a blank/incorrect location, or a BCD recovery identifier that does not resolve, and a valid existing winre.wim can be read from either \Windows\System32\Recovery or the intended recovery partition. The BCD store for the same Windows installation must also be readable.
Use the online branches whenever Windows starts. The offline branch in this writeup is intentionally limited to a proven UEFI/GPT Windows layout with an existing FAT32 ESP. Use it only from trusted Windows media, with all drive letters and the Windows loader GUID detected rather than assumed.
Does not apply when
Do not use this procedure when winre.wim is absent, zero length, unreadable, or rejected by DISM; when the recovery partition is missing, full, undersized, the wrong filesystem, or structurally ambiguous; or when repair requires partition creation, resizing, deletion, formatting, or a type/attribute change.
It also does not repair Safe Mode that opens and then crashes, 0xc0000017 RAM-disk allocation failures, a disk that disappears, a Windows Reset payload problem, or external recovery media that cannot see the Windows disk because a storage driver is missing. The offline repair branch does not apply to BIOS/MBR Windows; retain external recovery access and complete the online branch if Windows can start, or use a separately validated BIOS/MBR procedure.
Information that may remain unknown
The exact Windows build and the event that disabled or misregistered WinRE may remain unknown if the existing local image validates and the repair does not replace it. The image's exact location, readable state, owning Windows installation, intended recovery partition, BCD store, and Windows loader/recovery GUID relationship may not remain unknown.
If winre.wim must be replaced, its matching architecture, language, release, and servicing level become required and this writeup must stop.
Requirements
- Administrator access to running Windows, or current trusted Windows 10/11 installation media
- A proven readable existing
winre.wim - A readable BCD store belonging to the verified Windows installation
- A stable Windows and recovery volume
- Space on the Windows volume or an external drive for BCD and configuration backups
- The Windows RE location and BCD identifiers recorded before changes
- External installation media retained until built-in WinRE has been verified
The standing BitLocker assumption remains that the needed volumes are unlocked. Do not leave a temporary drive letter assigned to the recovery partition after testing.
Starting position
If built-in WinRE cannot open, first establish a working fallback. On another computer if necessary, create current official Windows installation media. Boot it, select Repair your computer, and confirm that Troubleshoot > Advanced options > Command Prompt opens. This supplies recovery tools without claiming that built-in WinRE is fixed.
If normal Windows starts, perform the online diagnosis and repair there. If Windows does not start, use the offline inspection branch. In recovery media, detect W: as the Windows installation, R: as the proven recovery partition, and S: as the proven ESP; never assume C:.
reagentc /disable and reagentc /boottore work only against the online Windows installation. Do not use them with /target.
Confirm the diagnosis
Online inspection when Windows starts
-
Open Command Prompt as administrator and capture the current configuration:
reagentc /info -
Create the rollback folder and preserve WinRE and BCD evidence:
md "%SystemDrive%\BootRepairBackup" md "%SystemDrive%\BootRepairBackup\FIX-034" reagentc /info > "%SystemDrive%\BootRepairBackup\FIX-034\reagentc-before.txt" bcdedit /enum all /v > "%SystemDrive%\BootRepairBackup\FIX-034\bcd-before-winre.txt" bcdedit /export "%SystemDrive%\BootRepairBackup\FIX-034\BCD-before-winre" -
Record these
reagentc /infofields exactly:Windows RE statusWindows RE locationBoot Configuration Data (BCD) identifier
-
If a
Windows RE locationis shown, map itsharddisk<number>\partition<number>values directly. Open DiskPart and inspect that exact object:diskpart list disk list volume select disk <reagentc-harddisk-number> list partition select partition <reagentc-partition-number> detail partition assign letter=R exitIf
R:is in use, assign another unused letter and substitute it below.If the location is blank, do not guess from partition size. Check
%SystemRoot%\System32\Recoveryfirst in step 6. If no staged image exists there, display the running system volume and map its volume number to its disk:echo %SystemDrive%diskpart list volume select volume <volume-number-matching-the-displayed-SystemDrive> detail volume select disk <detected-Windows-disk-number> list partition select partition <candidate-recovery-partition-number> detail partition assign letter=R exitA standard UEFI recovery-tools partition is NTFS and has type GUID
de94bba4-06d1-4d40-a16a-bfd50179d6ac. Continue only when the candidate containsR:\Recovery\WindowsRE\winre.wimand DISM validates it. If more than one recovery partition contains a plausible image and no existing registration or BCD evidence distinguishes them, stop rather than selecting the newest or largest one. -
If a registered or candidate recovery partition was identified and assigned
R:, verify its image without mounting or modifying it:dir /a R:\Recovery\WindowsRE\winre.wim dism /Get-ImageInfo /ImageFile:R:\Recovery\WindowsRE\winre.wim /Index:1 -
Check the default staging directory as a separate possible existing location:
dir /a "%SystemRoot%\System32\Recovery" dir /a "%SystemRoot%\System32\Recovery\winre.wim" -
If present, preserve the configuration XML files as evidence without editing them:
copy /y "%SystemRoot%\System32\Recovery\ReAgent.xml" "%SystemDrive%\BootRepairBackup\FIX-034\ReAgent-online.before-winre.xml" copy /y R:\Recovery\WindowsRE\ReAgent.xml "%SystemDrive%\BootRepairBackup\FIX-034\ReAgent-partition.before-winre.xml"One copy can report that the file was not found. Record which file actually existed.
Preserve the one
winre.wimthat passed DISM validation. Use the applicable command, not both blindly:copy /y "%SystemRoot%\System32\Recovery\winre.wim" "%SystemDrive%\BootRepairBackup\FIX-034\winre.before-registration.wim" copy /y R:\Recovery\WindowsRE\winre.wim "%SystemDrive%\BootRepairBackup\FIX-034\winre.before-registration.wim" dism /Get-ImageInfo /ImageFile:"%SystemDrive%\BootRepairBackup\FIX-034\winre.before-registration.wim" /Index:1If the Windows volume lacks room for the backup, use a proven external volume and substitute its path. Do not disable the current registration until a readable backup copy exists.
-
Inspect the BCD and locate the loader for the running Windows installation:
bcdedit /enum {current} /v bcdedit /enum all /v -
In the current Windows Boot Loader entry, record
recoverysequenceandrecoveryenabled. Enumerate the object whose identifier matchesrecoverysequence:bcdedit /enum {RECOVERYSEQUENCE-GUID} /vConfirm that its device and ramdisk paths refer to Windows RE. The identifier should also match the BCD identifier reported by
reagentc /info. Do not create or edit these objects manually. -
Interpret the online evidence:
- Disabled plus a DISM-readable image: Registration repair applies.
- Enabled but location is wrong, blank, or points to a missing path while another proven image exists: Re-registration applies.
- Enabled, correct location, readable image, and valid recovery BCD object: Registration is not the demonstrated cause. Test access and route by the resulting error.
- No valid image: Stop. Do not copy one from an unrelated computer.
- BCD cannot be enumerated: Stop and repair the system store first.
Offline inspection from Windows installation media
-
Inventory disks and volumes, and verify that the Windows disk uses the UEFI/GPT layout supported by this offline branch:
diskpart list disk list volumeContinue only when the verified Windows disk has a GPT asterisk and contains one attributable existing FAT32 ESP. If the disk is MBR/BIOS, stop this offline branch; do not substitute BIOS BCD paths into an unvalidated procedure.
-
Select the detected Windows volume, display its disk mapping, assign
W, and verify it:select volume <Windows-volume-number> detail volume assign letter=W exitdir W:\Windows\System32\Config\SYSTEM dir W:\Windows\System32\Config\SOFTWARERecord the physical disk number reported by
detail volume; every recovery and ESP candidate below must be on this same verified Windows disk. -
Display the offline registration:
reagentc /info /target W:\Windows -
Resolve the WinRE image location without assuming that
reagentcreported one:-
If
Windows RE locationcontainsharddisk<number>\partition<number>, require that disk number to match the verified Windows disk. Select that exact reported partition rather than a size-based candidate:diskpart select disk <reported-and-verified-Windows-disk-number> select partition <reported-recovery-partition-number> detail partition assign letter=R exitRequire NTFS, recovery type GUID
de94bba4-06d1-4d40-a16a-bfd50179d6ac, the expectedR:\Recovery\WindowsRE\winre.wim, and a successful DISM image-information check. If the reported partition is on another disk, has the wrong type, or does not contain a readable image, stop rather than silently choosing a different partition. -
If the location is blank, first check the offline default staging directory:
dir /a W:\Windows\System32\Recovery\winre.wim dism /Get-ImageInfo /ImageFile:W:\Windows\System32\Recovery\winre.wim /Index:1If both commands succeed, record
W:\Windows\System32\Recoveryas<verified-WinRE-directory>; no recovery-partition letter is required. -
If the location is blank and no DISM-readable staged image exists, inspect partitions only on the verified Windows disk:
diskpart select disk <verified-Windows-disk-number> list partition select partition <candidate-recovery-partition-number> detail partition assign letter=R exitContinue only when the candidate is NTFS, has recovery type GUID
de94bba4-06d1-4d40-a16a-bfd50179d6ac, containsR:\Recovery\WindowsRE\winre.wim, and DISM can read that image. RecordR:\Recovery\WindowsREas<verified-WinRE-directory>. If more than one correctly typed partition contains a plausible image and the offline registration or BCD does not distinguish them, stop.
-
-
Detect the existing ESP separately on the same verified disk. Require FAT32, ESP type GUID
c12a7328-f81f-11d2-ba4b-00a0c93ec93b, and the Microsoft EFI tree before assigningS::diskpart select disk <verified-Windows-disk-number> list partition select partition <verified-ESP-partition-number> detail partition assign letter=S exitStop on a missing, wrongly typed, unreadable, or ambiguous ESP; repair that demonstrated condition first.
-
Validate the applicable image path and the explicit UEFI BCD store:
dir /a R:\Recovery\WindowsRE\winre.wim dism /Get-ImageInfo /ImageFile:R:\Recovery\WindowsRE\winre.wim /Index:1 dir /a W:\Windows\System32\Recovery\winre.wim dism /Get-ImageInfo /ImageFile:W:\Windows\System32\Recovery\winre.wim /Index:1 bcdedit /store S:\EFI\Microsoft\Boot\BCD /enum all /vRun only the two image commands for
<verified-WinRE-directory>. The BCD command must succeed before registration is changed. -
Back up the offline evidence:
md W:\BootRepairBackup md W:\BootRepairBackup\FIX-034 reagentc /info /target W:\Windows > W:\BootRepairBackup\FIX-034\reagentc-offline-before.txt copy /y S:\EFI\Microsoft\Boot\BCD W:\BootRepairBackup\FIX-034\BCD.before-winre bcdedit /store S:\EFI\Microsoft\Boot\BCD /enum all /v > W:\BootRepairBackup\FIX-034\bcd-offline-before-winre.txt copy /y W:\Windows\System32\Recovery\ReAgent.xml W:\BootRepairBackup\FIX-034\ReAgent-offline.before-winre.xml copy /y R:\Recovery\WindowsRE\ReAgent.xml W:\BootRepairBackup\FIX-034\ReAgent-partition.before-winre.xmlThe XML copy for a location that is not in use can report that the file was not found. Record which configuration file actually existed; do not edit either file.
-
Record the exact Windows Boot Loader GUID, not the Windows Boot Manager GUID. Its
pathmust be\Windows\System32\winload.efi, itssystemrootmust be\Windows, and itsdeviceandosdevicemust resolve to the verified installation. If more than one loader remains plausible, stop.
Resolution steps
Branch A — Windows starts and WinRE is disabled with a valid existing image
-
If the valid image exists in the default staging directory
%SystemRoot%\System32\Recovery, first try the least invasive command:reagentc /enable -
Require
REAGENTC.EXE: Operation Successful.Then check:reagentc /info -
If the valid image instead resides in the proven recovery partition, register the directory containing it and enable WinRE:
reagentc /setreimage /path R:\Recovery\WindowsRE reagentc /enable reagentc /info/pathnames the directory containingwinre.wim, not the WIM file itself. -
If
/enablereports that the image was not found, stop. Recheck the exact path and DISM result; do not repeat the command or invent a new location.
Branch B — Windows starts, WinRE is enabled, but the registered location or recovery BCD link is wrong
-
Confirm that the valid image backup, BCD export, BCD listing, and REAgentC report from section 7 all exist and that DISM can read the backed-up image.
-
Disable the current online registration:
reagentc /disable -
Immediately recheck both possible image locations. Disabling can change where Windows stages the image, so do not assume it remained on
R::dir /a "%SystemRoot%\System32\Recovery\winre.wim" dir /a R:\Recovery\WindowsRE\winre.wim -
Run DISM against the copy that currently exists. Continue only when the image remains readable:
dism /Get-ImageInfo /ImageFile:<full-path-to-current-winre.wim> /Index:1 -
Register the directory containing that verified image:
reagentc /setreimage /path <directory-containing-current-winre.wim> -
Re-enable WinRE and inspect the new registration:
reagentc /enable reagentc /info bcdedit /enum {current} /v bcdedit /enum all /v -
Confirm that REAgentC created or repaired the recovery relationship. Do not use BCDEdit to hand-build
recoverysequence, ramdisk, or device objects.
Branch C — Offline UEFI/GPT re-registration from Windows installation media
Use this branch only when section 7 proved a UEFI/GPT Windows layout, the valid image directory, Windows installation, existing ESP BCD store, and Windows Boot Loader GUID. Do not adapt these commands to BIOS/MBR by changing only the BCD path.
-
Register the verified image against the offline Windows installation:
reagentc /setreimage /path <verified-WinRE-directory> /target W:\Windows -
Recheck the offline configuration:
reagentc /info /target W:\Windows -
Microsoft permits offline enabling from WinPE with
/osguidonly after BCDBoot has been run. If the current repair session already required and successfully completed BCDBoot for this exact installation and store, enable with the verified Windows Boot Loader GUID:reagentc /enable /osguid {VERIFIED-WINDOWS-LOADER-GUID}Immediately verify both the offline registration and the explicit store:
reagentc /info /target W:\Windows bcdedit /store S:\EFI\Microsoft\Boot\BCD /enum {VERIFIED-WINDOWS-LOADER-GUID} /v bcdedit /store S:\EFI\Microsoft\Boot\BCD /enum {REAGENTC-BCD-IDENTIFIER} /v bcdedit /store S:\EFI\Microsoft\Boot\BCD /enum all /vReplace
{REAGENTC-BCD-IDENTIFIER}with the exact identifier shown by the newreagentc /info /target W:\Windowsoutput. RequireWindows RE status: Enabled. In the intended Windows Boot Loader entry, requirerecoveryenabledto be enabled andrecoverysequenceto equal that identifier. In the separately enumerated recovery object, confirm that its device and ramdisk path use the proven WinRE image. Stop if either explicit enumeration fails, any identifier is missing or duplicated, or an object belongs to another loader. -
If BCDBoot was not required because the existing BCD is healthy, do not run BCDBoot merely to satisfy this branch. Retain the external recovery fallback, start Windows if possible, and complete
/enablethrough Branch A. -
If the explicit BCD store is missing, corrupt, or cannot be opened, stop. Repair the BCD/ESP condition first; do not create recovery objects manually.
Test the repaired built-in environment
-
When working online, request WinRE for the next startup:
reagentc /boottore shutdown /r /t 0Remove the Windows installation USB after
reagentc /boottoresucceeds and before restarting, while keeping it available for fallback. -
Confirm that the computer enters its built-in Windows Recovery Environment rather than the USB media.
-
Select Troubleshoot > Advanced options > Startup Settings > Restart.
-
Confirm that the numbered Startup Settings screen appears. Press Enter to return to Windows unless testing a specific Safe Mode condition is separately required.
-
After returning to Windows, run:
reagentc /info -
Remove the temporary recovery-partition drive letter:
diskpart select disk <recovery-disk-number> select partition <recovery-partition-number> remove letter=R exit
Expected results and branches
reagentc /enablesucceeds, status becomes Enabled, and/boottoreopens WinRE: The disabled-registration branch is confirmed.- Re-registering the proven path repairs Advanced startup: The image was present but its location or BCD relationship was stale.
REAGENTC.EXE: The Windows RE image was not found.persists: The path is wrong or no usable image exists. Stop; do not copy from another PC.REAGENTC.EXE: Unable to update Boot Configuration Data.appears: Inspect the explicit BCD store and its write access. Route to the demonstrated BCD or ESP problem before retrying REAgentC.- WinRE opens but Startup Settings alone is absent: Registration may no longer be the fault. Investigate image customization, servicing state, or the exact Windows recovery interface; do not cycle disable/enable repeatedly.
- Startup Settings opens but Safe Mode crashes: Access is repaired. Follow the stop code, named driver, or Safe Mode BCD condition in its own writeup.
- WinRE displays
0xc0000017or cannot create a RAM disk: Route to physical-memory availability and BCD bad-memory-list diagnostics. - Event ID
4502recordsErrorPhase 2, or the recovery partition lacks required free space: Use external media and defer to the partition-capacity procedure. Do not resize here. - External media opens recovery tools but the local image cannot: The fallback is working; built-in registration/image repair remains incomplete and must not be marked resolved.
Do not do this
- Do not create, delete, format, shrink, extend, move, or recreate a recovery partition.
- Do not change its GPT type or attributes under this writeup.
- Do not copy
winre.wimfrom a random computer, recovery image, ISO, or different Windows build. - Do not manually edit
ReAgent.xml. - Do not hand-create or delete
recoverysequence,ramdiskoptions, Windows Boot Loader, or recovery BCD objects. - Do not run
reagentc /enabletwice as a generic workaround. Microsoft documents that sequence only for a narrow historical language-resource defect. - Do not run BCDBoot solely because REAgentC is disabled when the existing BCD is healthy.
- Do not use offline
bcdedit /export; copy and enumerate the explicitly identified BCD file instead. - Do not run
/disableuntil a valid image and BCD rollback have been preserved. - Do not leave
R:assigned to the hidden recovery partition. - Do not use Reset this PC as a test of the repair.
- Do not convert a missing Startup Settings option into a Safe Mode driver diagnosis without first opening the numbered menu.
Rollback
If the computer was originally Disabled and enabling WinRE creates a new problem, return to the recorded state from an elevated online prompt:
reagentc /disable
reagentc /info
If the original registration pointed to a different location that was proven valid, restore it through REAgentC rather than editing XML:
reagentc /disable
reagentc /setreimage /path <previous-proven-valid-directory>
reagentc /enable
reagentc /info
If a REAgentC operation demonstrably damaged an otherwise healthy online BCD store, preserve the current output first and then import the saved store into the same running Windows installation:
bcdedit /enum all /v > "%SystemDrive%\BootRepairBackup\FIX-034\bcd-after-failed-winre-change.txt"
bcdedit /import "%SystemDrive%\BootRepairBackup\FIX-034\BCD-before-winre"
/import overwrites the system store. Use it only when the saved file belongs to this exact installation and restoring it is necessary.
For an offline rollback, boot trusted media, redetect W: and S:, preserve the changed store, and restore the copied original:
copy /y S:\EFI\Microsoft\Boot\BCD W:\BootRepairBackup\FIX-034\BCD.after-failed-winre-change
copy /y W:\BootRepairBackup\FIX-034\BCD.before-winre S:\EFI\Microsoft\Boot\BCD
The saved ReAgent.xml copies are evidence. Do not manually merge or edit them. Use REAgentC to restore registration. External installation media remains the recovery route if built-in WinRE cannot be safely restored.
Verification
reagentc /inforeportsWindows RE status: Enabled.Windows RE locationidentifies the intended recovery partition and\Recovery\WindowsREdirectory.- The registered
winre.wimremains present and DISM-readable. - The BCD identifier reported by REAgentC corresponds to the recovery object referenced by the verified Windows loader.
recoveryenabledis enabled for the intended loader and no duplicate recovery objects were manually added.reagentc /boottoreopens built-in WinRE without the USB media attached.- Troubleshoot > Advanced options > Startup Settings > Restart reaches the numbered Startup Settings screen.
- Settings System > Recovery > Advanced startup or Shift+Restart opens built-in WinRE on a second test.
- Windows returns to a normal desktop and completes two ordinary restarts.
- The temporary recovery-partition drive letter has been removed.
- No partition was resized, created, deleted, formatted, or retagged.
Confidence and stop conditions
Confidence is high when reagentc /info shows Disabled or an incorrect path, an existing local winre.wim validates with DISM, the BCD store is readable, and REAgentC registration alone restores both /boottore and Startup Settings. Confidence is moderate when BCD repair had to occur first because more than one defect was changed.
Stop if no valid local winre.wim exists, DISM cannot read it, the registered recovery partition is full or structurally wrong, several recovery partitions or loader GUIDs remain plausible, the BCD store cannot be opened, the disk is unstable, or 0xc0000017 identifies a RAM-disk/memory path. Stop the offline branch if the verified Windows disk is MBR/BIOS rather than UEFI/GPT; do not substitute a BIOS BCD path into these commands. Also stop whenever the next proposed action would create, delete, format, resize, move, or retag a partition, replace the image from an unverified source, force a dismount, or manually construct recovery BCD/XML data.