RECOMMENDED: Click here to fix Windows errors and optimize system performance
Windows has many tools that you can use to deploy an image from the operating system to other computer systems without having to run it individually manually. Sometimes, however, things may not go as well and you may encounter an error message saying,’Error when trying to copy boot files’. This happens when you try to apply bcdboot to a new image. Some of you may be confronted with the problem when trying to start the dual start.
Bcdboot is a command line utility that can be used to configure operating system boot files. You can create partitions on your hard drive or even repair damaged boot files. The cause of the error message is the inactive state of the system partition. If you receive the above error message, your operating system does not start and you can only look at the error message. However, this is not quite correct because we will show you how to solve the problem with a simple solution.
Fixed a BCD boot error when copying boot files via CMD.
If you start your WinPE player via the UEFI interface/options, BCDBOOT will by default try to work with the GPT and EFI firmware. If an EFI spare partition is missing because it has not been created, you get: Error when copying boot files. If you start your WinPE drive using the BIOS / LEGACY options, BCDBOOT tries by default to work with the MBR and firmware of the BIOS.
So, if you start a non-EFI disk on a USB stick, but your disk is GPT and UEFI, you must execute this command:
bcdboot c:\Windows /s S: /f EFI
Therefore, c means Windows Partition and S: is the EFI partition.
Conversely, if you cannot or do not want to run LEGACY, you should use this command to create the old MBR drive.
bcdboot c:\Windows /s S : /f BIOS
Where S: in this case is the system partition.
If you are not sure if the computer supports UEFI or LEGACY, you can try this command:
bcdboot c:\windows /s s : /f ALL
ALL means that the BIOS and UEFI files are copied to the hard disk.
Remember that S is the system partition, not the partition that contains Windows files.
Booting from the Windows Disk
You must boot from your Windows disk to solve the problem.
- Boot your computer using the Windows installation support.
- Choose the right time and type of keyboard.
- In the lower left corner, click on Repair Your Computer.
- On the Select Option screen, select Troubleshooting.
- On the Troubleshooting screen, click Advanced Options.
- Click on the Command prompt command.
- Type the following commands one at a time, then press Enter after each command line:
Bootrec /rebuildbcd /rebuildbcd /rebuildbcd /rebuildbcd
After about one minute after the last order, your machine shuts down. You can now delete the Windows media.
Restart your computer.
RECOMMENDED: Click here to troubleshoot Windows errors and optimize system performance
CCNA, Web Developer, PC Troubleshooter
I am a computer enthusiast and a practicing IT Professional. I have years of experience behind me in computer programming, hardware troubleshooting and repair. I specialise in Web Development and Database Design. I also have a CCNA certification for Network Design and Troubleshooting.