Updated on Apr 28, 2025
BCD, short for Boot Configuration Data, is a firmware-independent database for boot-time configuration data that contains critical information that can tell the Windows boot loader where to look for boot information. Thus, any BCD file corruption or loss will result in startup errors and unbootable problems. Below is a real case posted online:
Today, when I started my laptop, the following error message came with a blue screen saying: Your PC/Device needs to be repaired. The Boot Configuration Dara for your PC is missing or contains errors. File: \Boot\BCD and Error code: 0xc000014c. You’ll need to use recovery tools. If you don’t have any installation media (like a disc or USB device), contact your PC administrator or PC/Device manufacturer. — from Microsoft.
Have you ever encountered the same issue? Then, you will need to rebuild BCD to repair this error. EaseUS will introduce three applicable methods to help you seamlessly rebuild BCD and fix the boot BCD error in Windows 10 and Windows 11.
How to Rebuild BCD in Windows 10&11- 3 Ways
This section will contain three solutions and detailed instructions. Check the overall list first:
- Fix 1. Repair BCD with EaseUS Partition Master
- Fix 2. Apply Startup Repair
- Fix 3. Rebuild BCD via Bootrec.exe Tool
Share this post with multiple unbootable emergency rescue methods on your social media platform:
Fix 1. Repair BCD with EaseUS Partition Master
To rebuild BCD and repair the unbootable problems, you need a dedicated tool — EaseUS WinRescuer. This software is designed to manage users’ disks and provide versatile help, including repairing startup errors, fixing boot failures, and rebuilding MBR. Its intuitive interface and clear instructions can ensure a friendly experience for beginners.
With the assistance of its «Boot Repair» feature, you can effectively repair the BCD files and offer BCD and UEFI management.
Follow the tutorial below to repair the unbootable problem:
Step 1. Connect the USB drive/external drive to a working computer, open EaseUS WinRescuer, and click «Create Bootable Media.»
Step 2. Select EaseUS Boot Toolkits and other components you need. Then, click «Next.»
Step 3. Select your movable device and click «Go» to create an image on your USB drive/external drive. You can also burn the Windows ISO file to the storage media.
Step 4. Confirm the warning message and then wait for the creation process to complete.
Step 5. Connect the created bootable drive to the faulty computer and reboot it by pressing and holding «F2″/»Del» to enter the BIOS. Then, set the WinPE bootable drive as the boot disk and press «F10» to exit.
Step 6. Then, the computer will enter WinPE desktop. Open BootRepair, select the system you want to repair, and click «Repair.»
Step 7. Wait a moment, and you will receive an alert that the system has been successfully repaired. Click «OK» to complete the boot repair process.
After you repair the BCD error, reboot your computer to see if the issue is solved. Then, you can also try the «BCD menu» tool in the «Boot Repair» tab, which can ensure that the system can locate the BCD file correctly by explicitly defining its location.
Other Powerful Features of EaseUS Partition Master
- Check File System: Identify and repair file system errors contributing to boot issues.
- Rebuild MBR: Rebuild the Master Boot Record to fix boot problems.
- Partition Recovery: Safely recover lost or deleted partitions to retrieve valuable data.
- Disk Surface Test: Examine your disk’s health to ensure it’s not the source of the boot problem.
Download and install this trouble-solver from the button below:
Fix 2. Apply Startup Repair
Another reason for unbootable BCD error is corruption of the Operating System. You can use the Windows computer repair option to repair your operating system. Now let’s see how to take advantage of this feature:
Step 1. Click the «Repair Your Computer» option to launch the Windows Recovery Environment. Enter the «Advanced Options» under «Troubleshoot.»
Step 2. Next, choose «Startup Repair» to initiate the repair process. When it’s finished, Windows will restart on its own.
Fix 3. Rebuild BCD via Bootrec.exe Tool
When the BCD is corrupted, you can not boot from the hard drive. In this case, you can use Bootrec.exe command lines to rebuild BCD in the Command Prompt. Here is what you need to do:
Step 1. Navigate to «Troubleshoot» > «Advanced options» > «Command Prompt.»
Step 2. Write the CMD shown below and hit «Enter» for each:
- Bcdedit /export C:\BCD_Backup
- ren c:\boot\bcd bcd.old
- Bootrec /rebuildbcd
Step 3. Type exit to quit the process and restart your computer.
What Will Cause Boot BCD Errors?
As we know, if the Windows boot configuration data (BCD) is lost, corrupted, or incorrectly configured, the system will not boot. We rounded up some boot BCD errors:
- The boot configuration data store could not be opened. Access is denied.
- The boot configuration data store could not be opened; the system cannot find the file specified.
Then, what may cause the boot BCD errors?
- Corrupted or missing BCD file: The BCD file is responsible for booting the operating system. If it gets corrupted or deleted, it can lead to a BCD error.
- Incorrect BIOS settings: If the BIOS settings are not configured properly, it can result in a BCD error. This can happen due to changes to the BIOS settings or a faulty BIOS update.
- Malware or virus infections: Certain malware or viruses can target the BCD file and corrupt it, causing a BCD error.
- Hard drive failure: Problems with the hard drive, such as bad sectors or physical damage, can prevent the system from accessing the BCD file properly.
- Incorrect disk partitioning: If the disk partitions are not set up correctly, it can interfere with the BCD file and cause a BCD error.
Refer to the following article and learn further information about the BCD error:
Conclusion
This article has step-by-step instructions, clear explanations, and helpful guidance for rebuilding BCD. Then, we also rounded up the basic information of the boot BCD errors. If you are entangled in the BCD errors, we highly recommend trying EaseUS Partition Master. Its versatility extends beyond mere troubleshooting. It empowers you to repair various startup errors and unbootable issues. Hurry up and download this all-in-one software.
If you still have additional questions about rebuilding BCD, you can view and get your answers in this frequently asked question section:
1. Why does Windows boot BCD error 0xc00000f occur?
When any of the following scenarios come up, this problem will arise: corruption in the Boot Configuration Data (BCD), no or unknown reference to DEVICE/OSDEVICE in the boot configuration data. Except for winload.exe or \boot\BCD, the binary displayed in the screenshot is absent from the system disk.
2. Where can I find the BCD file?
For the MBR system disk, you can access the active partition and find the BCD registry file in the \Boot\Bcd directory. For the EFI-based operating system, you will discover the BCD file in its EFI system partition.
3. Can I manually edit the BCD file?
Yes, you can manually edit the BCD file by following the simplified tutorial below:
- Click «Start» > «Properties» > «Advanced System Settings.»
- In the «Advanced» section, select «Startup and Recovery,» then click «Settings.»
- Open the Default Operating System list to edit other startup settings. Then, click «OK.»
Open Command Prompt from the ASO menu and enter bootrec /rebuildbcd
Updated on April 10, 2022
What to Know
- The easiest solution to a BCD issue is to rebuild it, which you can do automatically with the bootrec command.
- You’ll need to open Advanced Startup Options if you’re using Windows 11, 10, or 8.
- From there, you’ll run commands to rebuild the BCD. It’s a very straightforward process.
If you see a BOOTMGR is Missing error or a similar message pretty early on in the boot process, you’ve got a BCD problem. This article explains how to rebuild the BCD.
These instructions apply to Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista.
How to Rebuild the BCD
Although it looks difficult, the whole process should only take around 15 minutes. Here’s what to do:
-
Access the Advanced Startup Options menu if you’re on Windows 11, 10, or 8, and then select Troubleshoot. If you’re using Windows 7 or Windows Vista, start System Recovery Options.
Similar problems can exist in Windows XP, but since boot configuration information is stored in the boot.ini file and not the BCD, correcting XP issues with boot data involves a completely different process.
-
In Windows 11/10/8, select Advanced options.
-
Select Command Prompt.
Command Prompt won’t start immediately. Your computer will show a «Preparing» screen for a short time while it readies the computer.
-
If Command Prompt asks for your account name and password, provide those details. Then, at the prompt, type the bootrec command as shown below, and then press Enter:
bootrec /rebuildbcd
-
The command will trigger a search for Windows installations not included in the BCD and then ask you if you’d like to add one or more to it.
You should see one of the following messages at the command line.
Option 1
Scanning all disks for Windows installations.
Please wait, since this may take a while...
Successfully scanned Windows installations.
Total identified Windows installations: 0
The operation completed successfully.
If you see that message, move on to Step 7. This result most likely means that Windows installation data in the BCD store exists but bootrec couldn’t find any additional installations of Windows on your computer to add to the BCD. That’s fine; you’ll just need to take a few extra steps to rebuild the BCD.
Option 2
Scanning all disks for Windows installations.
Please wait, since this may take a while...
Successfully scanned Windows installations.
Total identified Windows installations: 1 [1] D:\Windows
Add installation to boot list? Yes/No/All:
If you see this message, enter Y or Yes to the Add installation to boot list? question, after which you should see The operation completed successfully, followed by a blinking cursor at the prompt. Finish up with Step 10 toward the bottom of the page.
-
Since the BCD store exists and lists a Windows installation, you’ll first have to remove it manually and then try to rebuild it again. At the prompt, execute the bcdedit command as shown and then press Enter:
bcdedit /export c:\bcdbackup
The bcdedit command is used here to export the BCD store as a file: bcdbackup. There’s no need to specify a file extension. The command should return the following on screen, meaning the BCD export worked as expected:
The operation completed successfully.
-
At this point, you need to adjust several file attributes for the BCD store so you can manipulate it. At the prompt, execute the attrib command exactly like this:
attrib c:\boot\bcd -h -r -s
What you just did with the attrib command was remove the hidden file, read-only file, and system file attributes from the file bcd. Those attributes restricted the actions you could take on the file. Now that they’re gone, you can manipulate the file more freely (specifically, rename it).
-
To rename the BCD store, execute the ren command as shown:
ren c:\boot\bcd bcd.old
Now that the BCD store is renamed, you should now be able to successfully rebuild it, as you tried to do in Step 6.
You could delete the BCD file entirely since you’re about to create a new one. However, renaming the existing BCD accomplishes the same thing since it’s now unavailable to Windows, plus provides you with another layer of backup, in addition to the export you did in Step 5, if you decide to undo your actions.
-
Try rebuilding the BCD again. Type the following and then press Enter:
bootrec /rebuildbcd
It should produce this in Command Prompt:
Scanning all disks for Windows installations.
Please wait, since this may take a while...
Successfully scanned Windows installations.
Total identified Windows installations: 1 [1] D:\Windows
Add installation to boot list? Yes/No/All:
This means the BCD store rebuild is progressing as expected.
-
At the Add installation to boot list? question, type Y or Yes, followed by the Enter key.
You should see this on the screen to show that the BCD rebuild is complete:
The operation completed successfully.
-
Restart your computer. Assuming that an issue with the BCD store was the only problem, Windows should start as expected.
Depending on how you started Advanced Startup Options or System Recovery Options, you may need to remove a disc or flash drive before restarting.
If rebuilding the BCD didn’t solve the problem you were having, continue troubleshooting to fix freezing and other issues that may prevent Windows from booting normally.
FAQ
-
If you see an error like “Path Not Found C:\Boot,” run the command bcdboot c:\windows /s c (assuming C is your Windows drive). If you still have issues, use the Diskpart command to make your Windows installation the active drive.
-
Rebuilding the BCD doesn’t affect your personal data or settings in any way, so you can continue to use your computer as normal.
Thanks for letting us know!
Get the Latest Tech News Delivered Every Day
Subscribe
Download Windows Speedup Tool to fix errors and make PC run faster
BCD, or otherwise known as Boot Configuration Data, contains boot configuration parameters on how to start Windows. If the configuration file gets corrupted, you will have to rebuild BCD or Boot Configuration Data file. Usually, when BCD gets corrupted, it results in unbootable situations on Windows 11/10.
In earlier versions of Windows, the boot information was stored in the Boot.ini file. On EFI-based operating system, you’ll find the entry in the EFI firmware boot manager, which is available at – \EFI\Microsoft\Boot\Bootmgfw.efi.
BCD or Boot Configuration Data is a firmware-independent database file which has boot-time configuration data. Windows Boot Manager requires it and replaces the boot.ini that was used by NTLDR earlier. In the case of boot problems, you may be required to rebuild BCD.
- Boot your computer into Advanced Recovery Mode
- Launch Command Prompt available under Advanced Options.
- To rebuild the BCD or Boot Configuration Data file use the command –
bootrec /rebuildbcd
- It will scan for other operating systems and let you select the OS’s you want to add to BCD.
If this does not help, you can manually set the boot path. However, do so only if you are an expert, as it could create issues.
In the Command Prompt, type the following command and hit Enter:
bcdboot c:\windows /s c:
The BCDboot tool is a command-line tool that enables you to manage system partition files. If the system partition has been corrupted, you can use BCDboot to replace the system partition files with new copies of these files from the Windows partition.
Do note that you have to boot your computer into Advanced Recovery Mode and then execute this command, else you may see a Failure when attempting to copy boot files error message.
When you run this command, you will get a new Bootloader. Here “c” is the System drive. You should only do this when you know the exact drive on which Windows was installed.
If you are not comfortable with the commands, then you can use third-party tools such as EasyBCD or Dual-Boot Repair to repair your BCD file.
Lastly, we recommend you take a look at this post to how to repair & rebuild MBR or Master Boot Record.
Read: How to repair the EFI bootloader in Windows.
What does RebuildBCD do?
The RebuildBCD command is used to scan all disks for compatible Windows installations, and rebuild the Boot Configuration Data (BCD) store. It helps identify and add missing entries, ensuring proper boot management. Use this command to troubleshoot boot issues that require BCD reconstruction.
How to reset BCDedit settings?
To reset BCDedit settings, use the command bcdedit /deletevalue {default}
to clear unwanted entries or incorrect configurations. This action will remove any misconfigured settings, helping restore your boot manager settings to their original state.
Does rebuilding BCD delete files?
No, rebuilding BCD does not delete files. Bootrec.exe, fixmbr bootrec.exe, fixboot and bootrec.exe help us to repair the boot files, which will not affect any of the personal files and folder.
How to fix Windows boot error file :\ boot BCD error code 0xc000014c?
To fix the Windows boot error code 0xc000014c, use the Windows installation media to access the Command Prompt. Then, execute the commands: bootrec /fixmbr
, bootrec /fixboot
, and bootrec /rebuildbcd
. This sequence repairs the Master Boot Record (MBR) and rebuilds the Boot Configuration Data (BCD), resolving the error.
Related reading:
- BCDedit command fails with Total identified Windows installations 0 message
- Windows fails to boot; Automatic Startup Repair, Refresh, Reset PC also fails
Anand Khanse is the Admin of TheWindowsClub.com, a 10-year Microsoft MVP (2006-16) & a Windows Insider MVP (2016-2022). Please read the entire post & the comments first, create a System Restore Point before making any changes to your system & be careful about any 3rd-party offers while installing freeware.
Are you facing boot errors on your Windows PC? In this guide, we’ll show you a proven method to rebuild the Boot Configuration Data (BCD) file or recreate the System/EFI partition automatically. This approach works for Windows 11, Windows 10, Windows 8, and other versions. Whether you’re dealing with minor BCD corruption or a severely damaged boot configuration, this solution ensures a hassle-free recovery.
Commonly, the BCD can be rebuilt manually through CMD Commands if the BCD corruption is simple. But if the System or EFI partition is missing or infected by a virus, or if the rebuilding commands failed for any reason, you have to use this automatic batch script file to rebuild BCD or recreate the System/EFI volume by just one click and without common errors.
Before showing how to use this automatic tool, you have to know what is the BCD file, and what are the most common boot failure errors that indicate the BCD corruption.
What Is the Boot Configuration Data (BCD) File?
The Boot Configuration Data file or BCD is a settings file that contains the necessary information required by windows operating system to boot normally. If the BCD file is corrupted or missing, your computer will fail to boot with this error: “Your PC/Device needs to be repaired”, followed by one of the following blue screen error messages.
Common Errors Caused by BCD Corruption
The corrupted BCD can trigger a blue screen error messages with different error codes or can lead to a command error while trying to show the BCD using BDEDIT command, or while trying to rebuild the BCD using BOOTREC or BCDBOOT commands.
Examples of BCD-related blue screen errors:
- “The Boot Configuration Data file doesn’t contain valid information for an operating system.”
- Error Codes:
- 0xc0000098
- 0xc0000034
- 0xc00000bb
- 0xc000014c
- Error Codes:
- “The Boot Configuration Data for your PC is missing or contains errors.”
- Error Code: 0xc000000f
- File \Boot\BCD or
- \EFI\Microsoft\Boot\BCD
- Error Code: 0xc000000f
Command Failures Error Messages:
The following are some examples of BCD errors when repairing the BCD file from CMD:
- In case of missing of System or EFI partition, you may see the following error message:
- “A required device isn’t connected or can’t be accessed.”
- Error Code: 0xc000000f
- The boot configuration data store could not be opened.
- The requested system device cannot be found.
- Failure when attempting to copy boot files.
- BFSVC Error: Could not open the BCD template store. Status = C000000F
- Failure when initializing library system volume.
- Errors related to Bootrec RebuildBCD command:
- The System Cannot Find the Path Specified”
- “Element not Found”
All mentioned boot failures, BCD rebuild errors and all other BCD problems can be fixed easily and safely using this auto batch file, as they require a more robust solution than manual commands.
How to Boot into Advanced Recovery Menu?
You have to boot into Windows Recovery Environment (WinRE) in order to rebuild the BCD.
If the Windows recovery was enabled and intact before boot failure, your computer will reboot into Automatic Repair menu. From this menu, click on Advanced Option. Select Troubleshoot option and then select Advanced Options. If the computer reboot into Recovery Menu with option to Enter Recovery Environment like this, press F1 or F8 or another key to boot into recovery menu.
Both of those scenarios are true only if the BCD corruption is simple, but in most cases, you can’t boot into Recovery Environment if the BCD file is missing or severely corrupted, or if the Windows recovery is disabled or corrupted too. In such case, you have create a bootable USB using your mobile and then boot from the bootable USB in order to repair the BCD.
How to Rebuild the BCD Manually Using CMD?
For advanced users, the BCD can be rebuilt manually.
- If you want to rebuild the BCD manually, do the followings:
- Open the Command Prompt and execute the following commands at once or one by one:
BOOTSECT /NT60 SYS /FORCE
BOOTREC /FIXMBR
BOOTREC /FIXBOOT
BOOTREC /REBUILDBCD
- Type BCDEDIT and press Enter to identify the letter of windows partition
- Type the following command and press Enter (Replace the C with the letter of windows partition you have identified in previous step):
BCDBOOT C:\Windows
- Close the CMD window and then click on Continue to reboot into windows 10 or windows 11 login screen.
How to Rebuild the BCD Automatically Using a Batch File?
If the manual method failed to fix the BCD issue, you have to use the automatic batch file as followings:
- Download the VMTechsBCD.zip from this link or from this link using your mobile or in another computer.
- Extract the downloaded file into your mobile
- Connect a USB drive to your mobile and then copy the extracted folder and everything inside it into the USB.
- Plug-in the USB to the corrupted computer and then open Command Prompt
- Type DISKPART and press Enter
- Type LIST VOL and press Enter
- See if there is any volume without assigned letter and select it using SEL VOL followed by the volume number. For example, to select the volume number 2, type SEL VOL 2 and press Enter.
- Assign any free letter that is not assigned to another volume using this command:
- ASSIGN LETTER= followed by the desired letter. For example, to assign the letter V, execute this command: ASSIGN LETTER=V
- Repeat previous two steps to assign a free letter to all volumes that don’t have a letter.
- Press up Arrow key from keyboard to explore and use previous commands
- Type EXIT and press Enter to leave the DISKPART
- Type NOTEPAD and press Enter
- From File tab, select Open option
- Click on This PC and then locate the USB drive.
- Open the USB drive and then open VMTechsBCD folder
- Change “Files of type” option to “All Files”
- Right click on Auto-Rebuild-BCD-By-VMTechs file and then select, Run as Administrator
- This auto file will format the System or EFI partition and then rebuild the BCD automatically. Also it will create a new partition for the System or EFI if there is no one due to disk cloning or for any reason.
- If there is a separated system or EFI partition for the BCD in your computer, the auto batch will locate and then format it. After that, it will rebuild the BCD and enable the Recovery Environment. But you will be asked to ad windows installation to the BCD.
- Type Y or Yes to confirm addition of the identified windows into the BCD data.
- If you have a dual boot system, Type A or All to add all identified operating systems to the BCD file.
- If not sure, type Y or Yes to add the identified Windows installation that has :\Windows path only, and ignore the windows that has a Windows.old on its path by typing N or NO and pressing Enter.
- Once you see the successful message of Reagentc, press any key to close the auto CMD window
- Close all opened tabs and then click on Continue to restart your system.
NOTES:
- In older Windows 10 with MBR disk scheme or Legacy firmware, the Boot Configuration Data or BCD file may be stored in the windows partition. In such case, the CMD script will rebuild the BCD without formatting the partition.
- If you still have a blue screen error after a SUCCESSFUL rebuild using this auto batch file, then the problem is not related to the BCD. In such case, you have to identify the new error message and error code to know what is the source of new blue screen boot loop.
- To avoid errors when using the Auto batch file, make sure you have assigned a free letter to all volumes.
- Also make sure to copy the VMTechsBCD folder and everything inside it, including 7-Zip folder.
- If you need additional help, feel free to add your question in a comment, and we’ll do our best to help you.
VIDEO:
Watch this video to see how to rebuild BCD manually or automatically without errors step by step
Please follow and like us:
В современных версиях Windows информация для запуска операционной системы храните в файле конфигурации загрузки BCD (Boot Configuration Data). В этом файле хранятся данные об установленной Windows и параметрах ее загрузки. Если файл BCD удален или поврежден, Windows перестает загружаться. Также вы не сможете загрузить Windows, если повреждена MBR запись на жестком диске. В этой статье мы покажем, как корректно пересоздать файл хранилища данных конфигурации загрузки BCD и
Master Boot Record
(MBR) на примере Windows 10 и 11.
Содержание:
- Ошибка “The boot configuration data file is missing some required information”
- Автоматическое восстановление конфигурации загрузчика Windows
- Идентификация разметки дисков и букв томов
- Восстановление загрузочного сектора MBR в Windows 10/11
- Пересоздание BCD файла загрузчика Windows 10
Ошибка “The boot configuration data file is missing some required information”
Если файл BCD поврежден, отсутствует, если вы удалили / отформатировали отдельный раздел диска с меткой System Reserved (и размером 500Мб), специальный OEM раздел, то скорее всего при попытке загрузить Windows появится такое сообщение:
Your PC needs to be repaired The Boot Configuration Data file is missing some required information File: \Boot\BCD Error code: 0xc0000034
Также ошибка может выглядеть так:
The Boot Configuration Data for your PC is missing or contain errors. File: \boot\bcd Error Code: 0xc000000f
При повреждении MBR может быть ошибка No operating system found.
Автоматическое восстановление конфигурации загрузчика Windows
При появлении такой ошибки, в первую очередь попробуйте исправить проблему с загрузкой ОС с помощью режима автоматического восстановления (Startup Repair), который можно запустить из среды восстановления Windows RE.
Совет. Желательно периодически проверять работоспособность среды WinRE, и если она не работает, воспользоваться для ее восстановления методикой из статьи Восстановление среды WinRE в Windows.
Если автоматическое восстановление с помощью Startup Repair не помогло решить проблему, вам нужно загрузиться с загрузочного или установочного диска с Windows или в среде WinRe (Repair your computer -> Troubleshoot -> Advanced options -> Command Prompt), запустить командную строку и попробовать полностью пересоздать файл конфигурации загрузчика BCD и обновить MBR запись.
В этом примере я буду использовать установочный диск с Windows 10. Выберите в настройках BIOS первичным загрузочным устройство DVD диск или USB флешку с дистрибутивом Windows (в зависимости от того, с какого устройства вы хотите загрузить компьютер). Загрузитесь с установочного диска и на экране выбора языка установки нажмите сочетание клавиш Shift+F10. Перед вами откроется консоль командной строки.
Попробуйте восстановить BCD файл автоматически, выполнив команду:
bootrec /RebuildBCD
Перезагрузите компьютер и проверьте, загружается ли Windows (не забудьте изменить приоритет загрузочных устройств в BIOS). Если Windows не загружается, еще раз загрузитесь с установочного диска и откройте окно командной строки.
Идентификация разметки дисков и букв томов
Очень важно. Все инструкции, описанные ниже, подходят для обычных компьютеров с BIOS (или загружающихся в режиме UEFI legacy) и MBR таблицей разделов. На компьютерах с UEFI прошивками для пересоздания BCD нужно использовать следующе инструкци: восстановлению EFI загрузчика в Windows 10 или восстановление удаленного EFI раздела в Windows.
Как понять, используется ли у вас BIOS или UEFI система? Проще всего проверить тип таблицы разделов на диске, на котором установлена Windows: GPT или MBR. Для этого выполните команду:
diskpart
Затем выполните:
list disk
- Если у диска в столбце Gpt указана звездочка (*), значит на диске используется таблица разделов GPT. Это значит, что у вас компьютер с UEFI, и для восстановления загрузчика нужно использовать статью по ссылке выше.
- Если в столбце GPT звездочка отсутствует, значит у вас на диске таблица разделов MBR, и вы можете продолжить следовать данной инструкции.
Далее вам нужно идентифицировать локальные диски и разделы системы (скорее всего назначенные им буквы дисков будут отличаться от дисков, которые вы видели при работе в Windows). Проще всего это сделать с помощью утилиты diskpart. Выполните следующие команды:
diskpart
list vol
Перед вами появится список разделов в системе, назначенные им буквы дисков и их размер. В нашем случае к компьютеру подключен 1 жесткий диск, на котором имеются всего два раздела:
- Раздел System Reserved размером 500 Мб, которому назначена буква диска C:. На этом небольшом служебном разделе по-умолчанию хранится файл конфигурации загрузки BCD (подробнее)
- NTFS раздел размером 39 Гб, которому назначена буква D:. На этом разделе находится установленная Windows, программы и данные пользователя.
Важно. Запомните буквы дисков, назначенные разделам. Данные буквы дисков будут использоваться в последующих командах.
Восстановление загрузочного сектора MBR в Windows 10/11
С помощью утилиты bootrec.exe можно перезаписать данные в MBR и загрузочном секторе, поместим в них ссылки на загрузчик Windows (bootloader).
Попробуйте перезаписать основную загрузочную запись (MBR) системного раздела для совместимости с загрузчиком Windows (существующая таблица разделов не перезаписывается).
bootrec.exe /fixmbr
Добавьте в загрузочные секторы диска код для загрузки файла bootmgr ( диспетчера загрузки Windows):
bootsect.exe /nt60 all /force
Прежде, чем идти далее, попробуйте автоматически пересоздать конфигурацию загрузчика BCD командами (это самый простой способ для начинающих):
bootrec /FixBoot
– команда создает новый загрузочный сектор на системном разделе (перезаписывает загрузочную запись раздела PBR).
bootrec /ScanOs
– просканировать диски и найти установленные копии Window, которых нет в хранилище конфигурации загрузки
В случае успешного сканирования появится запрос на добавление записей о найденный Windows в BCD:
Scanning all disks for Windows installations. Please wait, since this may take a while... Successfully scanned Windows installations. Total identified Windows installations: 1 [1] D:\Windows Add installation to boot list? Yes/No/All:
bootrec /RebuildBcd
– пересоздать хранилище конфигурации загрузкика, добавить в BCD найденные на компьютере копии Windows/
После этого перезагрузите компьютер и проверьте загрузку Windows. Если ОС не загружается, следуйте инструкции.
Если команда bootsect.exe не найдена, попробуйте указать полный путь к ней:
X:\boot\bootsect.exe /nt60 all /force
Пересоздание BCD файла загрузчика Windows 10
Далее с помощью команды BCDedit нужно создать новый файл с конфигурацией загрузчика (предполагается, что у вас нет резервной копии BCD).
Ваши дальнейшие действия зависят от того, есть ли на диске отдельный раздел System Reserved или нет. В командной строке выполните:
diskpart
list vol
Проверьте, есть ли на диске компьютера системный раздел System Reserved. Его можно идентифицировать по метке тома, либо более точнее по размеру (500 Мб для Windows 10+, 350 Мб для Windows 8.1 и 100 Мб для Windows 7).
- Если раздела нет (вы случайно удалили его), можно хранить конфигурацию загрузчика BCD на основном диске, где находится каталог Windows. Чтобы создать конфигурационные файл загрузчика BCD и Bootmgr на указанном диске, выполните команду:
bcdboot C:\Windows /S C:
Должно появится сообщение
Boot files successfully created
. - Если раздел System Reserved у вас имеется, удалите старый (поврежденный) файл BCD и создайте вместо него новый:
del c:\boot\bcd
Если разделу System Reserved не назначена буква диска (по-умолчанию), вы можете сами назначить ее с помощью diskpart.
Запустите:
diskpart
Выберите диск (в моем случае в компьютере имеется всего один жесткий диск, а вы можете вывести список дисков командой list disk):
select disk 0
На скриншота выше видно, что раздел с меткой System Reserverd называется Volume 1. Выберите его:
select volume 1
Назначьте букву диска (я назначил букву C:, но вы можете использовать любую другую букву, в этом случае измените путь в следующих командах):
assign letter C:
exit
Создайте временный пустой файл bcd.tmp:
bcdedit /createstore c:\boot\bcd.tmp
Создайте запись для диспетчера загрузки bootmgr:
bcdedit.exe /store c:\boot\bcd.tmp /create {bootmgr} /d "Windows Boot Manager"
Импортируйте в BCD настройки из файла bcd.tmp:
bcdedit.exe /import c:\boot\bcd.tmp
Если команда bcdedit возвращает ошибку (
Ошибка создания хранилища. Отказано в доступе, access denied
) при доступе к файлу BCD, попробуйте снять с него атрибуты скрытый, read-only и системный:
attrib C:\Boot\BCD -s -h -r
Укажите, что загрузчик находится на служебном разделе System Reserved (ему назначена буква диска C: )
bcdedit.exe /set {bootmgr} device partition=c:
Настройте время ожидания при выборе ОС:
bcdedit.exe /timeout 10
Удалите временный файл:
del c:\boot\bcd.tmp
Итак, вы создали пустой BCD файл с параметрами загрузчика. Теперь в него нужно добавить записи об установленных на диске Windows .
Создайте в хранилище BCD новую запись для Windows 10:
bcdedit.exe /create /d "Windows 10" /application osloader
Команда должна вернуть уникальный идентификатор (GUID) данной записи загрузчика:
The entry {8a7f03d0-5338-11e7-b495-c7fffbb9ccfs} was successfully created.
Укажем, что bootmgr должен использовать данную запись по-умолчанию (после истечения времени ожидания при выборе ОС, для загрузки будет используется именно эта запись).
bcdedit /default {8a7f03d0-5338-11e7-b495-c7fffbb9ccfs}
Теперь в новой записи загрузчика осталось указать пути к имеющейся на диске установленной копии Windows 10. Ранее мы определили, что в среде WinPE диску с установленной Windows присвоена буква D:. Используйте эту букву диска в следующих командах:
bcdedit.exe /set {default}device partition=d:
bcdedit.exe /set {default} osdevice partition=d:
bcdedit.exe /set {default} path \Windows\system32\winload.exe
bcdedit.exe /set {default} systemroot \Windows
Осталось сделать данную загрузочную запись в BCD видимой (по умолчанию она скрыта):
bcdedit.exe /displayorder {default} /addlast
Итак, мы полностью пересоздали загрузчик Windows 10 (обновили файл BCD и перезаписали загрузочный сектор MBR).
Теперь нужно сделать раздел, на котором находится файл BCD с конфигурацией загрузчика активным (BIOS передает управлению загрузчику ОС с активным MBR раздел). Допустим, разделы на вашем диске распределены так.
- Volume 0 – загрузочная/установочная флешка (ISO образ) диск, с которого вы загрузили компьютер
- Volume 1 – раздел System Reserved с BCD загрузчиком (размер 500 Мб)
- Volume 2 – раздел с файлами Windows (здесь находятся каталог Windows, Program Files, Users и т.д.)
В этом примере нужно сделать активным раздел Volume 1 (в вашем случае определите номер раздела самостоятельно). Сделать раздел активным можно с помощью diskpart:
diskpart
list disk
sel disk 0
list vol
select volume 1
(файлы bootmgr и «\Boot\BCD» находятся на этом разделе)
active
exit
Проверьте, что раздел volume 1 теперь активный:
select vol 1
detail partition
Все верно (
Active: Yes
).
Теперь вы можете перезагрузить компьютер и убедится, что Windows загружается в штатном режиме.