How to fix the Failure when attempting to copy boot files error

Matthew Adams
by Matthew Adams
Windows & Software Expert
Affiliate Disclosure
Share this article:

To fix various PC problems, we recommend DriverFix: This software will keep your drivers up and running, thus keeping you safe from common computer errors and hardware failure. Check all your drivers now in 3 easy steps:
  1. Download DriverFix (verified download file).
  2. Click Start Scan to find all problematic drivers.
  3. Click Update Drivers to get new versions and avoid system malfunctionings.
  • DriverFix has been downloaded by 0 readers this month.

Some users utilize the Bcdboot command-line utility within WinPE (Preinstallation Environment) to deploy Windows on PCs. However, a “Failure when attempting to copy boot files” error aries for some users when they try to copy boot files. Consequently, users can’t deploy the Windows OS image when WinPE returns that error message.

How can Users Fix the “Failure When Attempting to Copy Boot Files” Error?

1. Copy Both UEFI and BIOS Files to the Disk

Some users have confirmed they’ve fixed the “Failure when attempting to copy boot files” error by copying both UEFI and BIOS files to disk. To do that, enter the ‘bcdboot c:\windows /s s: /f ALL’ command. The ALL at the end of that command ensures that both UEFI and BIOS files get copied.

bcdboot command failure when attempting to copy boot files


2. Set the System Partition As Active

  1. The “Failure when attempting to copy boot files” error can also be due to an inactive system partition. To fix that, users will need to insert a bootable USB flash drive into the laptop or desktop.
  2. Turn on the laptop or desktop.
  3. Click Repair your computer on the Windows Setup window.The Troubleshoot button failure when attempting to copy boot files
  4. Then select Troubleshoot and Advanced Options to open further options.
  5. Select Command Prompt to open the Prompt.
  6. Input ‘diskpart’ in the Command Prompt, and press the Return key.
  7. Enter ‘list disk’ and press Return to display a list of hard drives, which will probably include just one HDD.List disk failure when attempting to copy boot files
  8. Then enter ‘select disk 0’ and press Return if that’s the only hard drive listed. Users with more than one hard drive to select the one that includes the Windows install.
  9. Next, input ‘list partition’ and press Enter to display a list of drive partitions.list partition failure when attempting to copy boot files
  10. Thereafter, select the partition that includes the Windows installation. For example, enter ‘select partition 2’ if partition 2 includes Windows.
  11. Enter ‘active’ and press Return to set the selected partition as active.
  12. Then input ‘exit’ and press Enter to close the DiskPart utility.

Those are two resolutions that can fix the “Failure when attempting to copy boot files” error for users. Users who have fixed the same issue with other resolutions are welcome to share them below.

This article covers:

2 comments

Hi! This answer is right only for MBR. Today it’s not entirely relevant, because mainly GPT systems with UEFI-loading are used.

Yes, I’ve tried this method and it shows:
“The selected disk is not a fixed MBR disk. The ACTIVE command can only be used on fixed MBR disks.”

add a comment

Leave a Reply

Your email address will not be published. Required fields are marked *