The boot image cannot be found. Recovering the boot sector of the hard drive

Home / Laptops

Hi all! Today I will talk about a fairly common problem with operating systems of the family Windows Vista/7/8/8.1/10 - violation of the integrity of the MBR bootloader. No matter how hard Microsoft tries to take into account possible problems the operation of your software, it is probably impossible to foresee everything at the development and testing stage. Various third-party loaders (activators, other versions of operating systems, viruses) add problems to stability.

What is needed to restore the bootloader.

  1. Windows Vista/7/8/8.1/10 installation media.
  2. User.
  3. DVD drive.

Let's get started!

The easiest way to restore the bootloader. To use the startup repair tool, you must first start the environment Windows recovery RE.

To do this:

  • Set the BIOS to boot from installation media.
  • Select an item System Restore.

  • Next.
  • In the dialog box, select Startup recovery.

  • Follow further instructions.

After the Startup Repair tool completes, restart your computer. Try starting Windows in normal mode, without installation media.

If the problem persists, let's proceed with further actions.

Now we will look at restoring the MBR boot record using standard operating system tools. Which come either as part of the installation disk or as a component of the operating system. Namely BOOTREC.EXE And BOOTSECT.

BOOTREC.EXE- boot record recovery tool. Supports the following options, from which you can choose the one that suits you best.

This option writes the main boot entry compatible with Windows 7 or Windows Vista. It does not overwrite the existing partition table. This option should be used to troubleshoot problems with MBR corruption or if you need to remove non-standard code from the MBR.

/FixBoot

This option writes a new boot sector to the system partition using a boot sector that is compatible with Windows Vista or Windows 7. This option should be used if at least one of the following conditions is true.

  • The boot sector has been replaced with the non-standard Windows Vista or Windows 7 boot sector.
  • The boot sector is damaged.
  • After Windows installations Vista or Windows 7 An earlier version of the Windows operating system was installed on the computer. IN in this case to start the computer instead of the manager Windows boot(Bootmgr.exe) uses the Windows NT boot loader (NTLDR).

This option searches all drives for installed systems that are compatible with Windows Vista or Windows 7. It also displays any entries not included in the boot configuration data store. Use this option if you have Windows Vista or Windows 7 installed on your computer and do not appear in the boot manager menu.

/RebuildBcd

This option searches all drives for installed systems that are compatible with Windows Vista or Windows 7. It also allows you to select installed systems that need to be added to the boot configuration data store. This option should be used if you need to completely rebuild the boot configuration data store.

Let's get started!

To use the Bootrec.exe tool, you must first start the Windows RE recovery environment.

  • Insert installation Windows disk 7 or Windows Vista into the DVD drive and turn on the computer.
  • When prompted, press the key.
  • Select an item Restore your computer.
  • Specify the operating system you want to restore and click Next.
  • In the dialog box System Recovery Options select item Command line.
  • Type Bootrec.exe and press ENTER. will appear full list opportunities.
  • Write it down MBR sector what is the command for?

Bootrec.exe /FixMbr;

  • After pressing Enter, the computer will notify the user about the successful completion of the operation in the next line;
  • Next, carry out the procedure for recording a new boot sector by entering

Bootrec.exe /FixBoot;

  • All that remains is to enter Exit and try to restart the computer.

If not, we will describe how to restore the Windows bootloader in another way using the same program:

  • Sign in command line from the installation disk or flash drive.
  • Enter Bootrec /ScanOs, after which the utility will scan your computer for the presence of an operating system.

Bootrec/ScanOs

  • Write the command Bootrec.exe /RebuildBcd in the next line, the program will offer to add all found ones to the start menu Windows versions, including XP and others.

Bootrec.exe /RebuildBcd

  • All you have to do is agree with this by pressing Y and Enter in sequence, after which when loading the system you will have a choice of which OS to load - XP or Seven.

If that didn't help either. You can also fix the problem with the MBR with one more command. To do this, on the command line you need to enter bootsect /NT60 SYS, then Enter.

Team BOOTSECT allows you to write the specified program code of boot sectors that provide loading or ntldr, or bootmgr .

Command line format:
bootsect (/help|/nt60|/nt52) (SYS|ALL|< DriveLetter >:}

Bootsect command line options:
/help— display of help information;
/nt52— record program code boot sector, which provides the use of the ntldr bootloader for operating systems prior to Windows Vista.
/nt60- writing program code to boot sectors to ensure loading of the bootmgr file - boot manager for Windows Vista/Server 2008 and later operating systems Windows family.
SYS- recording will be performed in sectors system partition boot Windows, in the environment in which this command is executed.
ALL— program code will be written for all existing partitions that can be used to boot Windows.
DriveLetter— drive letter for which the program code of boot sectors will be rewritten.
/forceforced shutdown disk volumes used by other programs to provide exclusive access to the bootsect.exe utility
/mbr- changing the program code of the master boot record (MBR - Master Boot Record) without changing the disk partition table. When used with the /nt52 parameter, the MBR will be compatible with previous versions of Windows Vista. When used with the /nt60 parameter, the MBR will be compatible with Windows Vista and later operating systems.

bootsect /nt52 E:— create for drive E: boot records for Windows XP/2000/NT operating systems, i.e. for booting based on ntldr;
bootsect /nt60 /mbr C:— change the boot sectors of drive C: to ensure that the bootmgr manager loads, and this is Windows Vista/7/8/8.1/10;
bootsect /nt60 SYS— changing boot sectors for the partition from which the current Windows OS was loaded.

Let's also try using the command BCDBOOT. This is a tool that is used to create a system partition or restore the boot environment located on a system partition. The system partition is created by copying a small set of boot environment files from an installed Windows® image. Means BCDBOOT creates a boot configuration data store ( BCD) on the system partition with a new boot entry that allows you to boot installed image Windows.

For many years, Microsoft has been improving the recovery system for the Windows operating system, and in Windows 7 and Windows Vista it works almost automatically. If you boot from the Windows 7 installation disc and click Repair Computer, Windows Repair will launch and attempt to fix any errors it finds. She can fix large number problems, however, it is quite likely that the bootloader is damaged, and the recovery system cannot cope with this problem. In this case, you can restore the bootloader manually using the Bootrec.exe utility.

Application Bootrec.exe serves to correct errors associated with bootloader corruption and, as a result, the inability to start the Windows 7 and Windows Vista operating systems.

Sequence of actions

The utility will display help on the available command line switches.

Description of keys for launching the Bootrec.exe utility

Bootrec.exe /FixMbr- Launched with the /FixMbr switch, the utility writes a Windows 7 and Windows Vista-compatible Master Boot Record (MBR) to the system partition. Use this option to resolve problems with the master boot record being corrupted, or if you wish to remove non-standard code from it. The existing partition table is not overwritten in this case

Bootrec.exe /FixBoot- Launched with the /FixBoot switch, the utility writes a new boot sector compatible with Windows 7 and Windows Vista to the system partition. This option should be used in the following cases:

  1. The Windows Vista or Windows 7 boot sector has been replaced with a non-standard boot sector.
  2. The boot sector is damaged.
  3. Has been installed previous version Windows operating system after installing Windows Vista or Windows 7. For example, if Windows XP was installed, NTLDR (Windows NT Loader, Windows NT loader) will be used, the code of the standard NT 6 loader (Bootmgr) will be overwritten by the Windows XP installation program.

It should be noted that a similar effect can be achieved using the bootsect.exe utility, also located on bootable media Windows 7. To do this you need to run bootsect.exe with the following parameters:

bootsect /NT60 SYS- The boot sector of the system partition will be overwritten with code compatible with BOOTMGR. You can learn more about using the bootsect.exe utility by running it with the /help parameter.

Bootrec.exe /ScanOs- Launched with the key / ScanOs, the utility scans all disks for installed Windows Vista and Windows 7 operating systems. In addition, when using it, a list of found systems is displayed that are at the moment are not registered in the Windows boot configuration data store (Boot Configuration Data (BCD) Store)

Bootrec.exe /RebuildBcd- Launched with this key, the utility scans all disks for the presence of installed Windows Vista or Windows 7 operating systems. Found operating systems are displayed in a list from which they can be added to the Windows boot configuration data store (Boot Configuration Data Store). Also use this option if you want to completely rebuild the boot configuration data store. Before doing this, you must delete the previous storage. The set of commands could be as follows:

bcdedit /export C:\BCDcfg.bak
attrib -s -h -r c:\boot\bcd
del c:\boot\bcd
bootrec /RebuildBcd

In the above example, the current boot configuration store is exported to a file C:\BCDcfg.bak, the “system”, “hidden” and “read-only” attributes are removed from it, after which it is deleted with the DEL command and rebuilt with the command bootrec /RebuildBcd.

Of course the utility Bootrec.exe is very functional, however, it will not help if, for example, the file Windows boot loader bootmgr is corrupted or physically missing. In this case, you can use another utility, also included in the distribution package. Windows media 7 - bcdboot.exe.

Restoring the boot environment using BCDboot.exe

BCDboot.exe is a tool that is used to create or restore a boot environment located on the active system partition. The utility can also be used to transfer download files from one hard drive or partition into another.

The command line in this case might look like this:

bcdboot.exe e:\windows

Replace e:\windows to the path appropriate for your system. This operation will repair a corrupted Windows boot environment, including the Boot Configuration Data (BCD) store files, including the file mentioned above bootmgr.

Syntax of bcdboot command line parameters

The bcdboot.exe utility uses the following command line parameters:

BCDBOOT source]

source- Specifies the location of the Windows directory used as the source when copying boot environment files.

/l- Optional parameter. Sets the boot environment language. The default is English (US).

/s- Optional parameter. Specifies the drive letter of the system partition where the boot environment files will be installed. By default, the system partition specified by the BIOS firmware is used.

/v- Optional parameter. Enables detailed logging mode of the utility operation.

/m- Optional parameter. Combines the parameters of the newly created and existing boot storage record and writes them to the new boot record. If an operating system boot loader GUID is specified, combines the boot loader object with the system template to create a boot entry.

Resume. The article discussed the principles of working with utilities bootrec.exe And bcdboot.exe, which are used to resolve problems related to the inability to start the Windows 7 operating system due to a damaged or missing boot loader

The new Windows 10 OS from Microsoft has already gained popularity among millions of PC users around the world. But like all new products, Windows 10 is not without its flaws. Many users of this OS experience bootloader problems. Most often, this problem occurs due to a new operating system update policy.

Now in Windows 10 you cannot disable updates, as it was in Windows 7 and XP.

The problem with the bootloader itself appears when the user does not wait for the system update to finish and turns it off POWER button.

After the user turns on the computer again, he encounters such a message on his monitor screen.

This message indicates that your bootloader is damaged and needs to be repaired. It is also worth noting that turning off the computer during the update is not the only reason for the breakdown. The bootloader can still be damaged viruses and various malware. Another fairly common reason for its failure is faulty HDDs, in of which there are bad sectors , that is, the boot record will be located precisely on these sectors. Also, the cause of bootloader failure may be installing a younger OS on top of Windows 10. To help our readers restore the bootloader, we have prepared examples below in which we describe in detail how to restore it.

The easiest way to recover

Having seen a message about a bootloader failure, the first question a PC user has is how to restore the Windows 10 bootloader. In this example, we will describe the easiest way to restore it. For this example we will need .

If you do not have this disk and Internet access, you can make it on another computer with the same OS.

You can also use the original one for this task. installation disk with Windows 10. Well, let's get started. Insert the recovery disc into the drive and boot from it when the computer starts.

In the first window of the Recovery Disk Wizard, you must specify keyboard layout, after which the wizard menu will open.

In this window we will select the second tab “ Troubleshooting" and immediately move on to the next "".

IN additional parameters We are interested in the "" tab. After clicking on this link, the wizard will ask you to select an OS to restore it to start.

The computer under study has one operating system installed. Windows system 10, so there is only one choice in the wizard. After selecting the OS, the system will begin the procedure for finding computer faults and should repair the damaged bootloader.

If using this method you are unable to return Windows performance 10, then in the following examples we will describe the detailed process of recovering the boot sector using system utilities DiskPart And BCDboot.

Restoring the Windows 10 bootloader using the command line

For this method we also need Windows 10 recovery disk. Let's boot from the disk, as in the previous example, up to the "". In this menu we are interested in the “” tab, which we will go to.

First of all, we will launch the console utility on the command line DiskPart. To do this, enter the command diskpart in the console

We need this utility to displaying information about all local disks in the system. Now we need to find the bootloader partition number. Usually this hidden section, occupying 500 MB. This partition is created automatically by the Windows 10 installer. Next, to search for it in DiskPart, we will enter the command list volume

From the image you can see that the partition with the boot record is located in the first volume on drive C. The image also shows that Windows 10 itself is installed on drive D. Now we must exit disk program. You can do this with the exit command

After exiting DiskPart, enter the command bcdboot.exe D:\Windows Also note that the command uses drive D, since ten is installed on it.

This command completely recovered dozens of boot files. The principle of operation of this command is to use the utility BCDboot. The developers specifically created this utility to work with boot Windows files . It is also worth noting that thanks to the same utility, the Windows installer creates a hidden partition and copies boot files to it.

Restoring the Windows 10 bootloader using the command line (Method two)

In the second method we will also use the utilities DiskPart And BCDboot and try to rewrite the bootloader. To do this, let's launch DiskPart and find out on which disk our hidden partition and the partition on which Windows 10 is installed are located. Launching this utility is described above.

Now we need to format the hidden partition, which is located in the first volume. To do this, type the command select volume 1 which will select our hidden encrypted partition of 500 MB in size.

The next step is to format the selected partition. This is done in order to erase all files from it. For this operation, enter the command in the console format fs=FAT32

After formatting our partition, let's exit disk utility and enter the new command bcdboot.exe D:\Windows which was entered in the previous example.

This command will not fix the bootloader files as in the previous example, but will create new ones. As you already understand, this method is used if the first one does not work.

Another way to restore Windows 10 boot using the command line

This method requires a utility Bootrec. Unlike the previous utility, this utility does not restore bootloader files, but restores boot record. That is, she restores MBR- the first sector on the HDD. It is very important for the operating system that the MBR is intact and intact. When a computer starts, its BIOS first looks for the MBR in order to launch the operating system from it. For this example, let's launch the command line, as in previous examples. The utility in question has two main commands /FixMbr and /FixBoot The first command is required to fix MBR, and the second creates a new one. First of all, let's consider the situation when our MBR is damaged. To do this, enter the first command in the console.

The image above shows that the operation was successful, which means that the MBR has been restored.

Now let's consider a situation where the first method does not work, that is, we will create a new MBR sector. To do this, we will use the second command.

From the image above you can see that the new MBR sector has been created successfully.

The examples show how easy it is to restore the MBR sector using the Bootrec console utility. If you have problem with start m Windows 10, we recommend using this example first.

We clean the system from malicious software before restoring the bootloader

If the cause of the bootloader failure is malware, then this one malicious code must be removed before restoration. In this situation it will help you. This is a rescue disk that has many tools for restoring your computer, as well as treating it for viruses. You can download Dr.Web LiveDisk on its official website www.drweb.ru. This Live CD is based on Linux and is free. This disc is distributed as ISO image, which can be written as optical disk, and to a USB flash drive. After burning the image to disk, launch Dr.Web LiveDisk.

In the start menu, select the first item and continue downloading Dr.Web LiveDisk. After a few seconds, the Linux-based OS should start, which is actually Dr.Web LiveDisk.

In this operating system you can completely clean your computer of viruses and even make a backup of all information.

Also useful is the fact that this OS has full Internet support and a built-in browser. Firefox.

Let's sum it up

In conclusion, I would like to say that if you know all the intricacies of bootloader recovery, you can quickly fix your computer. It is also worth paying attention to the situation when it is impossible to restore the boot sector and the bootloader itself. In this case, you need to play it safe and use the funds full recovery systems. Such means are full image systems, created using the Windows 10 OS itself, as well as a program such as Acronis True Image. We hope that our material will help you restore the bootloader from the MBR, and your computer will function as before.

Video on the topic

© 2024 ermake.ru -- About PC repair - Information portal