In this article, we will be fixing the below issue in Windows Server 2012.

"The Boot Configuration Data for your PC is missing or contains errors."

Scenario

We have a Windows Server 2012 Virtual Machine and we have tried to extend the Operating System Partition (Active Partition) that extended properly but unfortunately, after the first restart, we got the below error.

The Boot Configuration Data for your PC is missing or contains errors.

Cause

Extending the Operating System Active Partition may cause damage to the Boot\BCD file.

What's the Boot Configuration Data?

The Boot Configuration Data (BCD) is a firmware-independent database for boot-time configuration data. It is used as new Windows Boot Manager. It replaces the "boot.ini" file that was used in old operating systems. For more details, check Windows startup process.

Solution

We have two options to solve this issue.

  1. Run Startup Repair.
  2. Rebuild the BCD file via the Bootrec.exe tool.
Run Startup Repair
  • Power Off the VM.
  • From the left side, go to VM Settings >Hardware tab > CD/DVD > Browse.
  • Locate the Windows Server 2012 R2 media (ISO/DVD).

    • Note
      It should be the same Windows version that you have already installed.

  • Set the default boot device to CD/DVD as the following.

    • Power On VM > Press F2 to open Bios Setup > Boot Menu > select CD-ROM Drive and press "+/-" to go up/down.
    • Press F10 to save and exit.
  • The VM will be rebooted with the default option for CD/DVD.
  • Press any key to boot from the CD/DVD.
  • At the Windows Setup Dialog, set your appropriate settings and click Next.
  • Click on "Repair your Computer" > Troubleshoot > Command Prompt.
  • Navigate to the recovery folder by typing cd recovery followed by an Enter.
  • Run Startup Repair by typing startrep.exe.
  • Wait until the repair is finished.
Unfortunately, in our case, the Startup Repair couldn't repair the issue! So, we will try to rebuild the BCD file via Bootrec.exe tool.

Rebuild the BCD file via the Bootrec.exe Tool

Before we get started, let us learn What's the Bootrec Tool?

In our case, we will use /RebuildBcd to rebuild the Bcd file by doing the following.

Steps

Conclusion

In this article, we have fixed "The Boot Configuration Data for your PC is missing or contains errors" issue. Also, we explored.
Reference

Windows failed to start: The boot configuration data for your pc is missing or contains errors

See Also

Use Bootrec.exe in the Windows RE to troubleshoot startup issues