Windows command guide
Fix bootrec /rebuildbcd finds 0 installations
When rebuildbcd says it found zero Windows installations, the problem is often not that Windows is gone. The repair tool may simply not be reading the boot configuration correctly.
This guide is written around the specific symptom-command match for fix bootrec /rebuildbcd finds 0 installations, not as a generic dump of terminal lines. That makes the page more useful for real troubleshooting and reduces the chance of running the wrong repair step.
diskpart
list vol
select vol <EFI_VOLUME>
assign letter=S
exit
bcdboot C:\Windows /s S: /f ALL
Best place to run it
Windows Recovery Environment Command Prompt is the right execution context for this page. Even when elevation is not always required, using the right shell prevents syntax mistakes and makes the output easier to trust.
Fast repair workflow
- Start from the exact symptom on this page: bootrec /rebuildbcd reports 0 installations
- Run the startup recovery line exactly as shown: diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL.
- This workflow is tuned for this repair, so avoid mixing it with unrelated repair commands too early.
- Re-check boot state with BCD or recovery info instead of repeating the same boot command blindly.
- If startup still fails, move to partition, file-system, or recovery-media diagnostics instead of stacking more write operations.
Recovery command sequence
Use this sequence when you want the page command in a cleaner, step-by-step recovery block.
:: Run these lines from Windows Recovery Environment when the guide calls for it
@echo off
echo Starting recovery command sequence...
diskpart
list vol
select vol <EFI_VOLUME>
assign letter=S
exit
bcdboot C:\Windows /s S: /f ALL
echo.
echo Review the output and restart only after the command sequence finishes.
pause
Verification commands after the repair
These follow-up commands help you check whether the repair actually changed the Windows state that matters, instead of assuming success from a single line.
bcdedit /enum
reagentc /info
What problem this command is trying to solve
This page targets broken or missing boot-configuration data where Windows files still exist but are not being discovered by rebuildbcd.
- bootrec /rebuildbcd reports 0 installations.
- You can still see the Windows folder from recovery tools.
- Startup repair loops or the system fails to find Windows normally.
How the command works
Instead of waiting for rebuildbcd to detect Windows, bcdboot writes a fresh boot configuration based directly on the existing Windows installation path.
When it makes sense to run it
Use it when the Windows directory is intact but automatic BCD discovery is failing.
Before you run this command
- Open the shell that matches diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL before you paste it.
- Confirm that the symptom really matches this guide, especially if you are seeing signs such as: bootrec /rebuildbcd reports 0 installations.
- Write down the exact startup or recovery message before you change boot-related data.
What result to expect
After running diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL, compare the result against the symptom that brought you here. The most useful checkpoint is whether bootrec /rebuildbcd reports 0 installations becomes less frequent, changes form, or produces a clearer error message. A command page is stronger when it helps you verify a real change instead of just assuming the line must have worked.
How to verify that it worked
The best verification step after diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL is to repeat the action that previously triggered the problem. If you can still see the windows folder from recovery tools still appears in exactly the same way, the command probably was not the whole answer and you should move to the next targeted check instead of assuming the page is finished.
Shell and execution context
This command usually does not need a full elevated repair context, but it still works best when you run it in the shell it was written for and read the output carefully.
Before you run it
Verify the correct Windows partition letter in recovery before running bcdboot. Drive letters can differ from normal booted Windows.
When this is probably the wrong fix
This is not the right first fix for a simple slow boot caused by startup apps alone. Use it when Windows cannot start properly, recovery keeps appearing, or boot data itself looks damaged.
What to do if it does not help
If diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL does not improve bootrec /rebuildbcd reports 0 installations, move to the next repair step that matches the same symptom family instead of piling on random commands. The best follow-up depends on whether the failure is mainly about startup, recovery, or boot configuration.
Frequently asked questions
Should I use diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL for this exact Windows symptom?
Use it when the behavior on your PC lines up with the repair target on this page: This page targets broken or missing boot-configuration data where Windows files still exist but are not being discovered by rebuildbcd.
What should I check right after diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL?
Check whether the original trigger still reproduces the same failure. For this page, a useful checkpoint is whether bootrec /rebuildbcd reports 0 installations becomes less frequent, changes form, or points you toward a more specific next step.
When should I not rely on diskpart list vol select vol <EFI_VOLUME> assign letter=S exit bcdboot C:\Windows /s S: /f ALL alone?
This is not the right first fix for a simple slow boot caused by startup apps alone. Use it when Windows cannot start properly, recovery keeps appearing, or boot data itself looks damaged.