Restoring bootmgr windows 7 via command line. We use the command line to restore the MBR sector. Recovering via the console in safe mode

For those who don't understand what we're talking about we're talking about, I’ll show you everything in pictures:

This is what the boot menu looks like when installing the latest Windows 8 OS.

This is what the menu looks like when installing the latest OS Windows Vista, 7.

Before Windows Vista (Windows 2000, XP), all changes to downloads were made to the file boot.ini. Boot.ini is a system file that contains information about the Windows operating systems installed on your computer. This data is displayed while the computer/laptop is booting. In order to change the boot parameters, just open the boot.ini files with any text editor and make changes.
Beginning with operating system Windows Vista (Windows 7, 8, 10) has replaced the boot.ini file with the Boot Configuration Data (BCD) file. This file is more versatile than boot.ini and can be used on platforms that use a means other than the BIOS to boot the system.

But how do you make changes to boot options in Windows Vista 7, 8, 10? There are two ways for this provided by Windows developers:

1 With GUI;

2 With command line.

Change boot options using GUI in Windows Vista, 7, 8.

To use this method, press the key combination "Win" + "R", In the "Run" line, type msconfig, and press Enter.

It must be said that quite a few settings are available this way, but for most users this will be quite enough. This tool will allow:

1) Get information about the current and default boot systems.
2) Edit time (timeout). After this time, the operating system set to boot by default will be loaded without user intervention. To do this, specify the time (in seconds) in the "Timeout" field.


3) Change the default system to boot. To do this, select which system you want to boot by default (without external intervention) and click the "Set as default" button.


4) Remove unnecessary entry from boot menu. Select the entry you want to delete and click the "Delete" button.

All changes will take effect after pressing the "OK" button and rebooting the system.

Change boot options using command line (bcdedit) in Windows Vista, 7, 8.

More ample opportunities The bcdedit utility provides a way to change boot parameters. Bcdedit is a command line tool designed to manage boot configuration data. It can be used for various tasks: Create new vaults, modify existing vaults, add boot menu options and more.

To get to know this command better, launch a command prompt with administrator rights and run the command:

/bcdedit/?

In this article I would like to go into more detail on examples of using the bcdedit command .

Example of using bcdedit.

Before you can start making changes to the Windows boot loader, you first need to create it backup copy. To do this, create a BootBackup folder on any disk and enter in the command line next command(the command line must be run as Administrator):

bcdedit /export D:\BootBackup\bcd

If you feel that something went wrong, in order to return everything to its original state, run the BCD restore command:

bcdedit /import D:\BootCopy\bcd

Where is D:\ drive where the BootBackup folder is located.

The next step is to find out basic information about your BCD. To do this, run the command bcdedit.

Where:
identifier– ID of a particular record;
device– shows the partition on which the download files are located (this can be the operating system or the BOOT folder);
osdevice– shows the section on which the system files operating system. Typically, the device and osdevice parameters are equal;
path– if device defined a disk partition that contains operating system files, then this parameter defines the rest of the path to the operating system loader;
default– shows the ID of the operating system that is loaded by default, if the operating system in which the command line was launched is loaded by default, the default parameter is assigned the value (current);
displayorder– shows the order in which records about bootable systems are located;
timeout– timeout (see above), the value is shown and set in seconds;
locale– indicates tongue boot menu or menu additional parameters downloads;
description– shows the name of the operating system displayed in the boot menu.

How to change the default operating system.
Specify the value /default and the ID of the OS that should boot by default.
bcdedit /default (ID)
Now the operating system with the specified ID will boot by default.

How to change the boot delay value
To change the delay before the operating system starts loading, run the following command:
bcdedit /timeout XX
where XX is the number in seconds, the default is 30 seconds.

Removing an entry from the BCD and boot manager done with the command:
bcdedit /delete (ID)
There is a peculiarity in executing the command: if the ID is specified famous recording, for example (ntldr), then the command must be executed with the /f switch:
bcdedit /delete (ntldr) /f
If the ID is written in alphabetical digital code, the /f switch is not needed.

In order to get more detailed information about the capabilities of the bcdedit utility, you must use the help bcdedit/?

If a user has a problem when Windows 7 does not start on a computer or laptop, then this article will help solve it. not an easy task. Starting Windows 7 is sometimes impossible due to errors occurring in the system after hardware problems or incorrect installation software, malicious utilities and so on.

But the most common reason why Windows 7 sometimes won’t load lies in the operating system itself.

Solution

In the case when all the initial stages Windows launch 7 on a PC or laptop runs fine, but Windows 7 still doesn’t start completely, which usually confuses novice users. Although if available detailed instructions, the question: “What to do?” will not appear even for beginners. If the problem is caused by hardware failure, then it will be indicated by a signal from the laptop speaker or desktop computer during POST test. If this is the case, then the OS will not start.

But if the problem is of a software nature and the process stops at the stage Windows downloads 7, this means that the user has encountered the most common problem that can be solved using an algorithm of typical actions.

Instructions for action

You must use an OS recovery tool. During the PC startup process, if Windows 7 does not start, the system often recommends that the owner of the computer or laptop select boot options. If for some reason such an offer has not been received, then the user can independently open this menu by clicking on the “F8” button. Then proceed to "Sevens".


What to do if the above instructions did not solve the problem?

To fix the problem when Windows 7 does not start, you need to use a CD with the OS:

  1. Insert the installation disk into the PC drive;
  2. Start the system from the disk (in the BIOS the appropriate order for booting the system from media must be set);
  3. In the window that appears, click on “Apply recovery functions that resolve OS boot problems” and click on “Next”;
  4. Then in the “OS Recovery Options” menu, click on “Startup Repair”;
  5. Wait until complete completion analyzing the system and eliminating the causes of failures;
  6. Reboot the PC;
  7. In BIOS, set the system to start with hard drive (When exiting the BIOS, be sure to save the adjustments made);
  8. Restart the computer again;
  9. Ready! Windows 7 will now boot normally.

Using the command line

If for some reason it was not possible to restore Windows using installation disk, then there is another way to do this through the command line.

First, you need to take the steps indicated in the paragraph about restoring normal loading of the “Seven”. The only changes are that you just need to specify the section “Command Line” in the menu.


What to do when you fail to achieve a positive result by following the above instructions?

If success was not achieved and the user has already reached this part of the article, then the problem cannot be classified as a typical failure of the OS boot distribution. It'll take everything further actions do in safe mode Windows. It is recommended to analyze drive “C” for the appearance of broken clusters.

To enter “safe mode” you must do the following:


Why are preventive measures important?

Windows 7 has special system, which can make special reference points, with the help of which, if necessary, it is restored. By using this protection function, even a novice user can always easily return the OS to a working state.

For example, in case of failures due to incorrect installation of applications, drivers and other utilities such as codecs, or when errors occur due to adjustments being made to the registry.

It should be noted that in “Seven” it is possible to allocate a fixed amount of memory on the hard drive specifically for such protection of the operating system. Implementation available in Windows 7 self-configuration protect files along with system data, or you can do this separately.

class="eliadunit">How to produce Windows 7 Boot Loader Recovery, if restoring the startup using the 7 installation disk did not help. I’ll briefly explain what’s going on: Windows 7 was first installed on the computer, then the second system needed Windows XP, after installation it naturally started alone, to boot two operating systems I used the EasyBCD program. Later, XP was no longer needed and I formatted the partition on which it was located from Windows 7. Now, when loading, there is nothing except a black screen. What can be done in this case? More details if possible. Sergey.

Restoring the Windows 7 bootloader

The most important thing is don’t worry, your problem is not complicated and, in principle, the remedy is Recovery Windows startup 7should have helped, let's try something else. Let me remind you that you cannot install an older operating system after a younger one. Windows 7 will never boot after installation on Windows computer XP, since the latter, when installed, overwrites the master boot record (MBR) with itself. So you installed additional manager loading EasyBCD, which is used to configure the boot of several operating systems and in turn has its own bootloader.

  • The master boot record (MBR) is the first sector on the hard drive, which contains a partition table and a small bootloader program that reads from this table the data from which partition of the hard drive to boot the OS, and then the information is transferred to the partition with the installed operating system, to download it. If in the main boot entry there is incorrect information about the location of the system, which means that when loading we will receive various errors, here is one of them Bootmgr is missing or we will see a black screen. The problem is being fixed restoring the Windows 7 boot loader.

When you uninstalled old XP along with EasyBCD, you left your computer to the mercy of fate with an incomprehensible boot record, and as a token of gratitude it gives you a black screen. To rectify the situation, we will carry out boot recoveryWindows 7, namely, we will overwrite the master boot record using the utility Bootrec.exe, located on the recovery disk or on the Windows 7 installation disk. We will also use this utility to write a new boot sector that is understandable to Windows 7.
Boot from a recovery disk or installation disk with Windows 7, then System Restore.

Here you need to select the operating system that you need to restore, you most likely have only one, and then, even if there is nothing here, we need to get to the command line.

In the command line window, enter the command Bootrec And Enter

comes out full information about the utility's capabilities. Select the Master Boot Record entry Bootrec.exe /FixMbr.

The operation was completed successfully. A new boot record is written to the first sector of the boot partition.
Second team Bootrec.exe /FixBoot writes a new boot sector.

Many years Microsoft company improved the operating room recovery system Windows systems, and in Windows 7 and Windows Vista it works almost perfectly automatic mode. If you boot from the installation Windows disk 7 and click " System Restore" ("Repair Computer"), system Windows recovery will be launched and will independently try to correct all errors that it finds. She can fix a large number of 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.

The Bootrec.exe application is used to fix errors associated with bootloader corruption and, as a result, the inability to start the Windows 7 and Windows Vista operating systems.

Sequencing

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 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. Existing table The partitions are 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. Bootable Windows sector Vista or Windows 7 has been replaced by a non-standard one.
  2. The boot sector is damaged.
  3. Has been installed previous version Windows operating system after Windows installations 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 BOOTMGR compatible code. You can learn more about using the bootsect.exe utility by running it with the parameter /help.

Bootrec.exe /ScanOs

Launched with the /ScanOs key, 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 this 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

The example above exports the current boot configuration store to C:\BCDcfg.bak, removes its system, hidden, and read-only attributes, removes it with DEL, and rebuilds it with bootrec /RebuildBcd.


Enlarge picture

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

Recovering 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.

Command line in in this case might look like this:

Bcdboot.exe e:\windows

Replace e:\windows with the path that matches your system.
This operation will repair the corrupted Windows boot environment, including the boot configuration data (BCD) store files, including the bootmgr file mentioned above.

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.

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

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.

Optional parameter. Enables the mode detailed logging utility operation.

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.

Summary

The article discussed the principles of working with the bootrec.exe and bcdboot.exe utilities, which are used to resolve problems associated with the inability to start the Windows 7 operating system due to a damaged or missing bootloader.

Friends, many of you have repeatedly had problems loading the operating system and asked the question how to restore loading Windows 7 and make sure that the operating system boots normally. In this article, we will look at the most common ways to restore the Windows 7 bootloader, which help in most cases.

1. Restore Windows 7 boot using the recovery tool

Boot from your Windows version 7. The main thing is that the system bit size matches (32-bit or 64-bit). Also, it is desirable that the release coincides (Home, Professional, Ultimate).

Instead of installing, select System Restore.

Go to the System Recovery Options window and select the Startup Repair tool.

After this, the recovery program will search for errors in the boot sector and boot Windows section 7 and, if detected, will try to correct them. After this, you will need to reboot the system and Windows 7 may boot normally.

If you were unable to restore the boot using the Windows 7 recovery tool the first time, try repeating this process 1-2 more times. This often helps since a repair tool can't always fix multiple problems in one pass.

2. Restore Windows 7 boot using the command line

If you were unable to restore your Windows 7 boot using the automatic repair tool, then try using the command line. Boot into your version of Windows 7 and select System Restore instead of installing.

Go to the System Recovery Options window and select the Command Prompt recovery tool.

After this, a window with a black background will appear in which you will need to write several commands.

Enter the following commands in turn:

bootrec/fixmbr
bootrec/fixboot
bootsect /nt60 ALL /force /mbr
exit

Switching the language is done using the key combination “Alt” + “Shift”. After entering each command (line), you need to press the “Enter” key.

Then restart your computer.

After this, in most cases the problems associated with boot sector And Windows boot loader 7 will disappear and the operating system will boot normally.

If after using the command line, Windows 7 still does not boot, then try using it again automatic tool boot recovery, as we discussed above.

3. Restore Windows 7 boot with system reinstallation

If you were unable to restore the operating system boot using the methods described above, you will most likely have to delete the partitions.

Before reinstalling Windows 7, copy all important files from your hard drive to or. This can be done using any boot disk LiveCD. Please note that external drive or flash drive must be connected to the PC before booting from the LiveCD, otherwise they may not be detected.

If you are unable to reinstall Windows 7 due to boot errors, remove all partitions from the disk using third party utility, for example, boot Acronis disk Disk Director. After that, try again by creating new partitions.

If at reinstalling Windows 7 at the disk setup stage (creating partitions, selecting a partition for installation) or when restarting the computer during the installation process, you will encounter previous mistakes download, then launch the command line and run the commands that we discussed above.

  • Errors when using Disk Utilities
  • Incorrect activators
  • Installing Windows on an existing partition along with a bootloader
  • In order to prevent loading problems in the future, you need to determine what exactly led to the problem and not repeat these mistakes. If you are unable to restore Windows boot, or other errors occur with the installation and operation of the system, please visit the website http://esate.ru where you will find instructions for solving various problems with the operating system.

    ASP900S3 75E120BW F120GBLSB
    SSDSC2BW240H601 75E250BW SSDSC2BW240A4K5 7KE256BW