Windows: Rebuilding BCD from Scratch

Warning: this guide requires basic knowledge of the command line.
Warning: there is a very strong possibility that your data is lost during this process. One mistyped character could result in wiping out all of your data. We strongly recommend that you back up your data before performing these steps. Cyberdragon takes no responsibility for data loss.

If you are not comfortable proceeding with this guide, please feel free to reach out to us and we will be more than happy to help.


You will need the following tools for this guide:

  • A USB stick with a copy of the Windows installer.

Due to many reasons, Windows' boot information may need to be rebuilt. This includes the Windows 11 upgrade installer saying that it can't determine if the disk has enough space (even/epseically when there's plenty of space), or it is bluescreening on boot with the error code 0xc000000e.

  1. Boot into your Windows Installer USB (see Boot + BIOS Keys)
  2. Press Next → Repair this computer (or press Alt-N → Alt-R)
  3. Troubleshooting → Advanced Options → Command Prompt
  4. Run the following:

    diskpart
    list disk
    sel disk [boot-drive]
    list vol
    

    Replace [boot-drive] above with the disk number of the boot drive; this is typically 0.

  5. Make a note of your boot partition's assigned letter (typically C). This will be the largest part shown. You will need this in step 5.

  6. Run the following:

    list part
    
  7. Make a note of the number for the partition labeled "System".

  8. Run the following:

    sel part [system-partition]
    assign letter=V:
    exit
    

    Replace [system-partition] above with the partition number labeled System

  9. Carefully run the following:

    format V: /FS:FAT32
    bcdboot [boot-drive]:\windows /s V: /f UEFI
    

    Replace [boot-drive] above with the boot partition's assigned letter you noted in step 2.

  10. Run the following:

    bootrec /rebuildbcd
    

You should now be able to perform the action you were attempting to do before!