Restore mbr boot record. Hard disk MBR recovery. Recovering Windows MBR bootloader using Live-disk by Sergei Strelec

MBR (in Russian - Master Boot Record) - a specific set of data, lines of code, partition table and signatures. It is required to download operating system Windows after turning on the computer. There are times when, as a result of various hardware and system failures, the ICBM is damaged or erased, which leads to the inability to start Windows. Recovery solves similar problems boot record MBR Windows 7. This article discusses several simple ways that you can restore records.

A bit of theory

After turning on computer BIOS selects the storage medium from which the download will be carried out. At this stage, the device needs to know which section hard disk contains system Windows files... MBR is a small program that is stored in the first HDD sector and points the computer to the correct partition to start the system.

If you incorrectly install the second operating system, the partition table may become damaged and the first Windows will not start. The same thing sometimes happens when there is a sudden power outage. If this happens, do not despair, the damaged data can be completely restored.

Restoring the boot record

In order to restore the MBR, you will need the installation disk from which you installed Windows (or any other one). If there is no disk, you can create a bootable USB flash drive with Win7. Algorithm of action:

Automatic recovery

First, it's worth providing a fix for the MBR. standard tools from Microsoft. Select Startup Repair. You do not need to do anything else, it will take some time, and the computer will report the completion of the process. Try starting Windows. If nothing happened, then you need to manually restore the ICBM.

Command line

This path requires several commands to be entered at the Windows command prompt.

  • From the System Restore menu, select Command Prompt.
  • Now you need to enter "bottrec / fixmbr". This command is used to write a new MBR compatible with Win 7. The command will remove non-standard parts of the code, fix the damage, but will not affect the existing partition table.
  • Next enter "bootrec / fixboot". This command is used to create a new boot sector for Windows.
  • Further "bootrec / nt60 sys". This command will update the MBR boot code.
  • Close the console, restart your computer and try to start the system. If the problem is still not resolved, you need to enter a few more commands.
  • Start the console again and enter "bootrec / Scanos" and "bootrec / rebuildbcd". Using these utilities, the computer will scan HDD for the presence of operating systems, and then add them to the boot menu.
  • Then enter "bootrec / nt60 sys" again and restart your computer.

TestDisk utility

If you do not have a bootable USB stick or disk, you can repair the damaged recording using a third-party program. To do this, you need to start another (working) OS. If you had only one Windows on your machine, you will have to connect the hard drive to another computer. Working with TestDisk is quite complex, so it is recommended that you familiarize yourself with the guides specific to this program.

One of the most effective steps to troubleshoot problems associated with booting windows is to repair bootable Windows entries 10/7 / 8.1 with new UEFI and GPT markup or BIOS with MBR markup. One of the common reasons the Master Boot Record can get corrupted is due to an infection malware or file corruption in this sector. Improper shutdowns can also damage the boot record (MBR). Sometimes the problem happens when Linux Grub is installed and Windows cannot detect it. In some cases, you may receive the error Bootmgr is Missing or BCD when you turn on your computer. In such cases, you can run a bootloader repair to fix these problems.

How to repair Windows 10 bootloader

You must prepare, as your computer will not boot to your desktop and additional boot options may not be effective. Therefore, you need Windows 10 with the same bitness (x32 or x64) that you are going to repair, and preferably the same version. You must boot in all of the below methods from a bootable USB stick in order to run the command line. Remember that after restoring the bootloader, some errors may appear and you just need to restart your PC a couple of times to get the bootloader to get used to it.

Start the installation of Windows 10 from a bootable USB flash drive and go to the installation point. Then click below on " System Restore"to get into advanced download options.

Method 1... Once you get into the advanced download options, then go to " " > "Extra options"> and select" "Wait for the process to finish and the Windows 10 bootloader should recover.

Method 2... In the same advanced boot options, go to " Troubleshooting" > "Extra options"> and run" Command line".

To begin with, we will make sure on which local disk the system is located on which we want to restore the bootloader. To do this, on the command line, do the following three commands, pressing Enter after each:

  1. diskpart
  2. list volume- displays a list of sections.
  3. exit- exit from the tool for working with discs.

In my case, the screenshot below shows that the local drive on which Windows 10 is installed is not "C", but "D". You will most likely have "C", but be careful, you must determine where your system is installed. Once you have determined what letter your system is under, then enter the following command to restore the Windows 10 bootloader:

  • bcdboot D: \ windows

Method 3... If you are using a Windows system with the new UEFI and GPT partition scheme, then you need to find hidden section with the FAT32 file system (it is approximately 90-300 MB). If you have BIOS and MBR markup, then file system will be NTFS (about 500 MB). In my case, this is NTFS. So, we run the command line through a bootable USB flash drive, as described above in the ways, and write the commands:

  1. diskpart- launches a tool for working with disks.
  2. list volume- displays a list of sections.
  3. select volume 3- Choice hidden volumes (in my case it is NTFS, you may have a hidden FAT32).
  4. format fs = ntfs or format fs = fat32- formatting the selected volume (depending on which one you have).
  5. assign letter = E- We assign a new letter to the volume (I assigned what was already there).
  6. exit- exit from the tool discpart.
  7. bcdboot D: \ Windows / s E: / f ALL- copy the bootloader files. (In my case, the D: drive is the volume on which Windows itself is located, E: is the letter we assigned to the hidden partition).
  8. diskpart- launches back the tool for working with disks.
  9. list volume- display a list of sections.
  10. select volume 3- Number hidden volume to which we assigned the letter.
  11. remove letter = E- we delete the letter so that the partition is not displayed in the system when we reboot.


Method 4... In this method, we will use the tool Bootrec.exe... Enter the following commands on the command line one after the other:

  1. bootrec / RebuildBcd
  2. bootrec / fixMbr
  3. bootrec / fixboot

Log out and reboot your system.

In some cases, you will need to run an additional command:

  • bootsect / nt60 SYS or bootsect / nt60 ALL

If Windows does not start when you turn on your computer, the process hangs on a black screen, then the hard disk boot record (MBR) may be damaged.

External manifestations

When an error appears on the screen, doubts disappear.

Other information about a malfunction of the HDD bootloader may also be displayed.

The text information can be different depending on the classification of the error. But when the word boot is mentioned, it is clear that there is a problem with the boot.

How to recover the MBR is reported on this page.

Causes

Pay attention to the common causes of HDD boot sector failures.

Two types of bootloader

Older systems prior to Windows XP used the NT Loader (NTLDR). In Windows 7, Vista and subsequent versions of the OS, UEFI and EFI began to be used. Therefore, old and new systems are usually not installed on the same PC. Otherwise NTLDR overwrites UEFI.

Third party software

Errors in the HDD boot sector can occur when using even popular programs for the hard drive partition. I've had this happen with Acronis. This happens because such software replaces the disk boot drivers with its own. This can corrupt the original MBR. Therefore, it is better to use the built-in hard disk partitioning methods from Windows.

Viruses

Viruses sometimes introduce their "order" in the MBR. Therefore, after restoring the HDD boot, check the computer with anti-virus programs.

If you are sure that the cause is viruses, then clean the PC of them before repairing the MBR. To do this, there are utilities of well-known antivirus companies, for example - Kaspersky Rescue Disk. They are provided free of charge on official websites with instructions for use.

Any of these programs is included in the set of software for CD or DVD, which allows you to boot from a CD, find and remove viruses on the HDD.

Windows 7 Boot Repair

Sector repair is performed from a CD or from a USB flash drive with the operating system installation package.

  1. First, insert the DVD into the drive or flash drive into the USB connector with the Windows distribution.
  2. Then you need to allow launching from these devices. This is done in the BIOS settings.

Changing download sources

Technology of the following order:


Be sure to press F10 when you exit, otherwise the changes will not be saved!

Working from a CD or flash drive

Proceed in the following order:

  1. After rebooting, an inscription will appear at the bottom: "Press any key ...". It is asked to press any key. Click. Otherwise it will not work. If the inscription has already disappeared, repeat all over again. To do this, press three keys at once: Ctrl + Alt + Del. This will cause the computer to restart.
  2. When you boot from DVD or USB stick, a window will appear Windows installations... At the bottom left, select "System Restore".
  3. They will offer to connect network capabilities, select languages ​​or a drive letter. Do not change anything and come to the choice of systems.
  4. Highlight the required Windows and check the box next to "Use recovery tools ...".
  5. If the required system is not there, then it should appear when you click "Download drivers".
  6. Continue with the "Next" button.
  7. In the next window, select "Startup recovery", and the MBR can be reanimated in automatic mode.
  8. If the sector did not work, then press "Command line".
  9. On the command line, call the Bootrec utility and write for it to repair the MBR: bootrec / fixmbr... End each command with the Enter key.
  10. Then you create a new boot sector: bootrec / fixboot... To exit the program, type exit and remember to press Enter.

If the fixes didn't help

There is another MBR resuscitation team - bootsect / NT60 SYS... After that, try to boot again.

In case of an unsuccessful attempt, write on the command line like this: bootsect / rebuildbcd. This will search for operating systems installed on your PC.

Now try to log into Windows again. Please note that there will be one more systems in the list now. Try to go to each of them. It should work!

Non-standard way

If you have not saved all the options for recovering the sector, then it is recommended to reinstall Windows. And no matter how much you want to do it sometimes! Isn't it true?

I thought so too and decided to put another small system next to it. What does "small" mean? This is a bootloader system. It is empty: I did not install drivers and my programs on it, because I do not work in it. But it loads!

What was needed, I achieved: a working boot area appeared on the hard drive. Now I can log into the old system normally. The downside is that it lost about 14 GB of disk space. If you are not afraid of this, you can take this method into service.!

How to fix a sector in Windows 8-10 and Vista?

For Vista and later versions of Windows, the same methods are suitable as for the "seven", only the design is different. For example, in the G8 he is like that.

But the points remain the same. Therefore, we will not describe them. Use the instructions above for Windows 7.

On Windows XP

In the "expish", the principle of reanimating the sector is similar. But the entrance is a little different. Now you will see it:

  1. After booting from the CD, the system files are copied to the hard drive.
  2. Then the action selection window appears.
  3. You choose the recovery option using the console, so press the R key.
  4. Next, they will ask about which system to enter. When she is alone, there is nothing to choose, but she needs to answer. To do this, press the number "1" on the keyboard, if it says: "1. C: \ WINDOWS ", - or click on another number that stands next to the required OS.
  5. Then a black screen of DOS mode appears. This is the same command line, but for the entire monitor area. Are typing fixboot and press Enter.
  6. You will be asked if you want to write a new boot sector.
  7. The answer is yes: write Y. Let me remind you that you press Enter after each command entered or your answer.
  8. Then a record of the successful operation appears, if everything went right.

Hello everybody! 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 work of your software, it is probably impossible to foresee everything at the stage of development and testing. Various third-party loaders (activators, other versions of operating systems, viruses) add problems to the stability of the work.

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 Startup Repair, you must first start Windows RE Recovery Environment.

For this:

  • Configure BIOS to boot from installation media.
  • Select item System Restore.

  • Further.
  • In the dialog box, select Launch recovery.

  • Follow further instructions.

After the startup repair tool finishes, restart your computer. Try starting Windows normally, without any installation media.

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

We will now look at restoring the MBR boot record using staff resources operating system. Which come either as part of the installation disc or as a component of the operating system. Namely BOOTREC.EXE and BOOTSECT.

BOOTREC.EXE- boot record recovery tool. Supports the options listed below, from which you can choose the most suitable one.

This parameter writes a master boot record compatible with Windows 7 or Windows Vista to the system partition. It does not overwrite the existing partition table. This parameter should be used to troubleshoot a corrupted master boot record or to remove a non-standard code from the master boot record.

/ FixBoot

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

  • The boot sector has been replaced with a non-standard Windows Vista or Windows 7 boot sector.
  • The boot sector is corrupted.
  • After installing Windows Vista or Windows 7, more than early version operating system Windows. V this case Instead of the Windows Boot Manager (Bootmgr.exe), the Windows NT Boot Loader (NTLDR) is used to start the computer.

This option searches all drives for installed systems compatible with Windows Vista or Windows 7. It also displays any entries not included in the Boot Configuration Data store. Use this option if your computer has Windows Vista or Windows 7 operating systems installed that 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 the installed systems that you want to add to the Boot Configuration Data Store. Use this parameter if you want 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 disk Windows 7 or Windows Vista into the DVD drive and turn on the computer.
  • Press the key when prompted.
  • Select item Repair your computer.
  • Specify the operating system that you want to restore and click the button Further.
  • In the dialog box System recovery options select item Command line.
  • Type Bootrec.exe and press ENTER. Will appear full list opportunities.
  • Write down the MBR sector, for which there is a command

Bootrec.exe / FixMbr;

  • After pressing Enter, the computer will notify the user about the successful completion of the operation in the next line;
  • Next, follow the procedure for recording a new boot sector, for which enter

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 a different way using the same program:

  • Enter the command line from the installation disk or flash drive.
  • Enter Bootrec / ScanOs, and then the utility will scan your computer for an operating system.

Bootrec / ScanOs

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

Bootrec.exe / RebuildBcd

  • It remains to agree with this by pressing successively Y and Enter, after which, when the system boots, you will have a choice which of the OS to load - XP or 7.

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.

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

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

Bootsect command line parameters:
/ help- display of reference information;
/ nt52- Writing the boot sector program code that allows the use of the ntldr boot loader for operating systems prior to Windows Vista.
/ nt60- writing the program code to the boot sectors to ensure that the bootmgr file is loaded - the boot manager of Windows Vista / Server 2008 and later OS of the Windows family.
SYS- the recording will be made to the sectors of the Windows boot system partition in the environment of which this command is executed.
ALL- writing of the program code will be performed for all existing partitions that can be used to boot Windows.
DriveLetter- the letter of the drive for which the program code of the boot sectors will be overwritten.
/ force- forced disconnection of 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 option, the MBR will be compatible with earlier Windows Vista versions. When used with the / nt60 option, 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 the C: drive to ensure that the bootmgr manager is loaded, and this is Windows Vista / 7/8 / 8.1 / 10;
bootsect / nt60 SYS- change the boot sectors for the partition from which the current Windows OS was loaded.

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

Repairing the Windows 7 boot loader - performing actions to restore the operating system after a problem occurs booting Windows... Due to a system failure, the user may lose data, personal files on the computer.

At one point in time, the operating system will not be able to boot on the computer. Various messages appear on the screen (not always in Russian), which say about a problem with Windows loading.

The main causes of problems with Windows bootloader 7:

  • user actions: an attempt to use hidden system partitions, incorrect changes to boot files using EasyBCD, etc.;
  • system failure;
  • exposure to malicious software;
  • the appearance of bad blocks on the hard disk of the computer;
  • the operating systems are installed on the computer in the wrong order;
  • hardware problems.

The problem with the bootloader must be solved, otherwise you will not be able to use Windows, because the system does not start on the computer. Problems can be fixed in a radical way: again on a PC.

If there is, created by the system tool, or with the help of third-party programs need to restore from backup image Windows created in advance. Unfortunately, many users do not pay enough attention backup systems, so these methods will not work for them.

How to repair Windows 7 bootloader? To restore operating system boot files, use the built-in Windows tools: automatic recovery startup, as well as using the BootRec and BCDboot utilities included in the operating system, launched from the command line.

Before using the operating system tools, you need to know the layout of the hard drive. Modern computers have a rigid layout style GPT disk and the new BIOS is UEFI, and in Windows times 7, the disks used MBR markup, and the now outdated BIOS. Some computers, Windows 7 64 bit, installed on UEFI and GPT disks, but mostly Windows 7 PCs use MBR (Master Boot Record) markup.

In this article, we will look at instructions on how to restore the bootloader in Windows 7 using system tools: first, we will perform an automatic recovery, and then we will try to restore the bootloader from the command line.

To perform operations to restore the bootloader, you will need either an installation DVD with the operating system, or a bootable USB flash drive 7. Bootable media needed to be able to upload to personal computer Windows RE (Windows Recovery Environment) recovery environment, with which you can try to solve the problem with the inability to start the system.

Performing a Windows 7 recovery automatically by the system tool

The easiest way: automatic recovery of the boot partition on the hard disk using the operating system tool. This action takes place without user intervention, it is only necessary to boot on the computer from the boot disk.

Immediately after starting the computer, using the keyboard keys, you need to enter the Boot Menu to select external device For loading: DVD disc or USB stick... Which keys should be pressed depends on the manufacturer of the equipment, inquire in advance.

Another way: you can enter the BIOS and set the boot priority there from the connected device: USB drive or DVD drive.

In this example, I am using the Windows 7 installation disc, all actions from the bootable USB flash drive are performed in a similar way.

In the first window of the Windows setup program, click on the "Next" button.

In the window asking you to start installing the operating system on your computer, in the lower left corner, click on "System Restore".

In the "System recovery options" window that opens, a search for installed systems will start.

After a while, a message will appear stating that problems have been found in the boot parameters of the computer.

Click on "Details" to view a description of the fix.

To start automatic troubleshooting with system boot, click on the "Fix and restart" button.

After restoring the bootloader, the Windows 7 operating system will boot up on the computer again.

Automatic troubleshooting by means of the system can be started in a slightly different way:

  1. In the "System Recovery Options" window, activate the option "Use recovery tools to fix problems when Windows startup... Select the operating system to recover, "and then click the" Next "button.

  1. In the window for selecting recovery tools, click on "Startup Repair".

  1. Wait until the end of the operation to automatically eliminate problems that prevent the system from starting.

If the issue is not automatically resolved, go to the following methods, which will require the user to manually enter commands at the Windows command prompt.

Repairing the Windows 7 boot loader using the Bootrec utility

The next method involves restoring the Windows 7 bootloader via the command line. For this we use the Bootrec.exe utility. This method only works with disks that have an MBR.

From the boot disk, you need to enter the Windows recovery environment as described above.

In the "System Recovery Options" window, click on the "Command Prompt" option.

The Bootrec.exe utility uses the following basic commands:

  • FixMbr - the parameter writes the Master Boot Record (MBR) to the system partition of the disk, compatible with Windows 7, the existing partition table is not overwritten
  • FixBoot - using the command, a new boot sector is written to the system partition, which is compatible with Windows 7
  • ScanOS - performs a search on all disks of installed systems compatible with Windows 7, displaying entries that are not in the system configuration store
  • RebuildBcd - search all disks of installed systems compatible with Windows 7, select systems to add data to the boot configuration store

The FixMbr command is used to fix the Master Boot Record as well as to remove invalid code from the Master Boot Record.

The FixBoot command is used under the following conditions: damaged boot sector, the boot sector has been replaced with a non-standard boot sector, an earlier one was installed on a Windows 7 computer Windows version(Windows XP or Windows Vista).

The ScanOS command searches all disks for operating systems compatible with Windows 7. As a result, all entries related to other operating systems installed on the computer that are not displayed in the boot manager menu will be displayed.

The RebuildBcd command allows you to discover and add to the repository the boot configurations installed on the system computer. This parameter is used to completely rebuild the system boot store configuration.

In the command line interpreter window, enter the command (after entering the commands in the command line, press the "Enter" key):

Bootrec / fixmbr

If the problem persists, you may need to enter the following command:

Bootrec / fixboot

The rest of the commands are used if the computer has multiple operating systems.

Close the command line, and in the "System Recovery Options" window, click on the "Restart" button.

How to repair Windows 7 command line bootloader using BCDboot utility

Using the bcdboot.exe utility, you can restore the Windows 7 boot loader on computers with MBR or GPT hard disk partitioning styles.

Boot from the removable device, go to the window with the choice of a system recovery method, and then run the command line. Another option: in the very first window, press the Shift + F10 keys on the keyboard to enter the command prompt window.

In the Command Prompt window, enter the command to run the DiskPart utility:

Diskpart

To display information about the disks on your computer, enter the following command:

List volume

We need to find out the drive letter (volume name) on which the operating system is installed.

The volume name (drive letter) in Diskpart utility may differ from the drive letter in Explorer. For example, in my case, in Explorer, the system partition has the letter "C", and in diskpart it is indicated by the letter "E".

To get out of diskpart utilities enter:

Bcdboot X: \ windows

In this command: "X" is the letter of the drive on which the operating system is installed. In my case, this is the letter "E", you may have a different volume (disk) name.

Close Command Prompt.

In the "System Recovery Options" window, click the button to restart the computer.

Conclusions of the article

If you have problems with the Windows 7 boot loader, you need to restore the system boot files by booting on the computer from the boot Windows disk... You can restore damaged or missing files using the operating system tools: automatic troubleshooting Windows downloads using the Bootrec and BCDboot utilities run from the command line in the recovery environment.

Experienced PC and Internet user