Saturday, January 3, 2015

Complete Tutorial On BCDEdit Command of Command Line Tool
बी.सी.डी. ईडीट कमाण्ड का कम्प्लीट ट्यूटोरियल

Information:

This will show you how to use BCDEDIT in the command prompt and avoid the need of third party applications like EasyBCD.

Note:

Bcdedit is a really powerful tool that Windows Vista and Windows 7 uses to manage the boot loader entries.BCDEDIT needs a boot manager to boot your system.A boot manager is a file that contains necessary information that instructs the system how to boot/start an operating system.

>>>> Windows 7 and Vista boot manager file is \bootmgr
>>>> Windows XP boot manager file is \ntldr

BCDEDIT can support other boot managers too, like grub for Linux. You just have to place the boot file on the root of the boot manager partition. e.g. \grldr and you have a grub boot loader enabled.
Bcdedit edits a file called bcd , which is located in Windows 7's hidden partition under \boot\bcd.
In Vista, its located under C:\boot\bcd.

Warning:

You must be logged on in an administrator account to be able to do this tutorial.

To Use bcdedit:

1. Open an elevated command prompt.
2. Type bcdedit and press enter.
NOTE: By typing just bcdedit you just list your boot entries.

A boot entry consists of 4 main elements:
1. Identifier
The identifier is how the system has named the boot entry.
2. Device
The device is the drive or virtual image that the system will use to boot the boot entry.
3. Path
The path is the location on the device where the bootloader file is found.
4. Description
The description is the friendly name we give to our boot entry, e.g. "Windows 7" 

You see next to the identifiers their UUIDs in {}. The UUID is the unique codename that the system gives to each boot entry and cannot be changed.

The standard identifier UUIDs are explained below:

{bootmgr} = the boot manager
{current} = the OS you selected to boot at startup.
{default} = the default OS selected to boot the PC.
{ntldr} = Windows Legacy OS Loader (for windows xp)

There are others like {memdiag} or {ramdisk} but they can't be of much use right now.
   
Warning

IMPORTANT: 
make a backup of your bcd file first. To do that, type:
bcdedit /export C:\SAVEDBCD
This will create a file c:\savebcd which is your boot entry backup.

If you mess up, you can always undo changes by:
bcdedit /import c:\savedbcd
Now to see how we can control the above entries, here are some examples:

bcdedit /set {current} description "My edited Windows Boot Entry"
NOTE: This changes the title of the boot menu entry "{current}".

bcdedit /set {ntldr} device partition=E:
NOTE: This tells bcd that Windows XP partition is drive E:

bcdedit /set {ntldr} path \ntldr
NOTE: This tells bcd that the ntldr file which is the winxp bootloader is on root folder "\" (of drive e: as stated above)

bcdedit /displayorder {ntldr} /addfirst
NOTE: This places Windows XP as the first OS on the menu list.

 bcdedit /default {ntldr}
NOTE: This places Windows XP as the default OS to boot first with.

bcdedit /displayorder {33342343-3424-2342342342-2344} /addlast
NOTE: This tells bcd that the boot entry with UUID 3334... should be the last entry on the menu.
You can copy your existing VISTA or Windows 7 boot entry to another identical. Then you can change settings on the new entry to experiment. You will always have the first entry available, so it's safe to play with.

bcdedit /copy {current} /d "New Windows 7 boot entry I just copied!"
this will give you a line:
NOTE: The entry was successfully copied to {4c21825f-e04b-11dd-b760-00195b61617a}. The {4c21825f-e04b-11dd-b760-00195b61617a} is the UUID of the new entry that the system just created. Yours will be different than mine! This is its identifier and you should use this to address that entry. 

Example:
bcdedit /set {4c21825f-e04b-11dd-b760-00195b61617a} numpoc 2
NOTE: This adds the 2 CPU Core support during boot, like you do in msconfig.

bcdedit /deletevalue {4c21825f-e04b-11dd-b760-00195b61617a} numproc
NOTE: This deletes the numproc parameter from entry {4c21825f....}
bcdedit /delete {}

FEEL LUCKY..



No comments:

Post a Comment