The Windows XP and Windows 2000 Recovery console is quite an unspoken hero... If you know how to use it! Not only are you able to fix common problems with Windows such as the boot menu, corrupt/missing files, chkdsk: checkdisk (scandisk) and various other health remedies; but you are able to run System Restore to go back to an earlier state!
Yes, not many people realise this. But how to you take advantage of the power of the Windows Recovery Console? Let Guru Guy tell you how!
Firstly, you can access the Recovery Console from the Windows XP (Professional or Home) or Windows 2000 CDROM. (Note: Manufacturers recovery disks generally don't work as they are restore disks, not the original Setup CDROM). Just insert it into your computer and boot from it (check BIOS will enable this feature or access it from an optional boot menu - usually by F12).
Once the Windows Setup (TEXTMODE) is loading, press "R" to launch the Recovery Console which will do so once the setup files are read from the CD. (The other method to get into the recovery console without the CD is to load it from the boot menu, which has to be installed in the first place - see below.)
--------------------------------------------------------------------------------
To restore a restore point in the recovery console:
Type the following:
1. CD c:\
2. cd "system volume information\_resto~1"
3. DIR (this lists restore points)
4. Pick a restore point using folder dates to guide you.
5. CD RPx (x being restore point number to use)
6. CD SNAPSHOT (this takes you into the folder containing all snapshot files)
7. Copy the Registry backups in the restore point and overwrite them to the C:\
COPY _Registry_machine_system c:\Windows\System32\Config\System
COPY _Registry_machine_software c:\Windows\System32\Config\Software
COPY _Registry_machine_sam c:\Windows\System32\Config\Sam
COPY _Registry_machine_security c:\Windows\System32\Config\Security
COPY _Registry_user_.default c:\Windows\System32\Config\Default
8. Type "exit" to leave recovery console and reboot machine.
--------------------------------------------------------------------------------
Available commands for the Recovery Console:
Attrib changes attributes on one file or subdirectory;
Batch executes commands that you specify in the text file, Inputfile. Outputfile holds the output of the commands. If you omit the Outputfile parameter, output appears on the screen;
Bootcfg modifies the Boot.ini file for boot configuration and recovery;
CD (Change directory) operates only in the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources;
Chkdsk The /p switch runs Chkdsk even if the drive is not flagged as dirty. The /r switch locates bad sectors and recovers readable information. This switch implies /p. Chkdsk requires Autochk. Chkdsk automatically looks for Autochk.exe in the startup folder. If Chkdsk cannot find the file in the startup folder, it looks for the Windows XP Setup CD-ROM. If Chkdsk cannot find the installation CD-ROM, Chkdsk prompts the user for the location of Autochk.exe;
Cls clears the screen.
Copy copies one file to a target location. By default, the target cannot be removable media, and you cannot use wildcard characters. Copying a compressed file from the Windows 2000/XP Setup CD-ROM automatically decompresses the file;
Del (Delete) deletes one file. Operates within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources. By default, you cannot use wildcard characters;
Dir displays a list of all files, including hidden and system files;
Disable disables a Windows system service or driver. The variable service_or_driver is the name of the service or driver that you want to disable. When you use this command to disable a service, the command displays the service's original startup type before it changes the type to SERVICE_DISABLED. Note the original startup type so that you can use the enable command to restart the service;
Diskpart manages partitions on hard disk volumes. The /add option creates a new partition. The /delete option deletes an existing partition. The variable device is the device name for a new partition (such as \device\harddisk0). The variable drive is the drive letter for a partition that you are deleting (for example, D). Partition is the partition-based name for a partition that you are deleting, (for example: \device\harddisk0\partition1) and can be used instead of the drive variable. The variable size is the size, in megabytes, of a new partition;
Enable enables a Windows system service or driver. The variable service_or_driver is the name of the service or driver that you want to enable, and start_type is the startup type for an enabled service. The startup type uses one of the following formats:
SERVICE_BOOT_START
SERVICE_SYSTEM_START
SERVICE_AUTO_START
SERVICE_DEMAND_START
Exit quits the Recovery Console, and then restarts the computer;
Expand expands a compressed file. The variable source is the file that you want to expand. By default, you cannot use wildcard characters. The variable destination is the directory for the new file. By default, the destination cannot be removable media and cannot be read-only. You can use the attrib command to remove the read-only attribute from the destination directory. The option /f:filespec is required if the source contains more than one file. This option permits wildcard characters. The /y switch disables the overwrite confirmation prompt. The /d switch specifies that the files will not be expanded and displays a directory of the files in the source;
Fixboot writes a new startup sector on the system partition;
Fixmbr repairs the startup partition's master boot code. The variable device is an optional name that specifies the device that requires a new Master Boot Record. Omit this variable when the target is the startup device;
Format formats a disk. The /q switch performs a quick format. The /fs switch specifies the file system;
Help If you do not use the command variable to specify a command, help lists all the commands that the Recovery Console supports;
Listsvc displays all available services and drivers on the computer;
Logon displays detected installations of Windows and requests the local Administrator password for those installations. Use this command to move to another installation or subdirectory;
Map displays currently active device mappings. Include the arc option to specify the use of Advanced RISC Computing (ARC) paths (the format for Boot.ini) instead of Windows device paths;
MD (Make directory) operates only within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources;
More/Type displays the specified text file on screen;
Rd (Remove directory) operates only within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources;
Ren (Rename) operates only within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources. You cannot specify a new drive or path as the target;
Set displays and sets the Recovery Console environment variables;
Systemroot sets the current directory to %SystemRoot%.
--------------------------------------------------------------------------------
Recovery Console Rules
Several environment rules are in effect while you are working in the Recovery Console.
Type set to see the current environment. By default, these are the rules:
AllowAllPaths = FALSE prevents access to directories and subdirectories outside the system installation that you selected when you entered the Recovery Console.
AllowRemovableMedia = FALSE prevents access to removable media as a target for copied files.
AllowWildCards = FALSE prevents wildcard support for commands such as copy and del.
NoCopyPrompt = FALSE means that you are prompted by the Recovery Console for confirmation when overwriting an existing file.
When running the Windows Recovery Console, allow it to start in full admin mode (allows file copy which is disabled by default):
To do so, in Windows you need to run gpedit.msc go to:
Computer Config->Windows Settings->Security Settings->Local Policies ->Security Options
Enable "Recovery console: Allow floppy copy and and access to all drives and folders".
Taken from the Windows Tweaks & Hacks page.
--------------------------------------------------------------------------------
To install the Recovery Console in Windows to the Startup Boot Menu:
Insert the Windows XP CD into the CD-ROM drive.
Start->Run.
Type d:\i386\winnt32.exe /cmdcons (where d is the drive letter for the CD-ROM drive).
A Windows Setup Dialog Box appears. The Windows Setup Dialog Box describes the Recovery Console option. To confirm the installation, click Yes.
Restart the computer. The next time that you start your computer, "Microsoft Windows Recovery Console" appears on the startup menu.
To delete the Windows Recovery Console:
Click Start, click My Computer, and then double-click the hard disk where you installed the Recovery Console.
On the Tools menu, click Folder Options, and then click the View tab.
Click Show hidden files and folders, click to clear the Hide protected operating system files check box, and then click OK.
At the root folder, delete the Cmdcons folder and the Cmldr file.
At the root folder, right-click the Boot.ini file, and then click Properties.
Click to clear the Read-only check box, and then click OK.
Open the Boot.ini file in Microsoft Windows Notepad, and remove the entry for the Recovery Console. It looks similar to this:
C:\cmdcons\bootsect.dat="Microsoft Windows Recovery Console" /cmdcons
Save the file and close it.
Taken from the Make Windows more reliable page.
Yes, not many people realise this. But how to you take advantage of the power of the Windows Recovery Console? Let Guru Guy tell you how!
Firstly, you can access the Recovery Console from the Windows XP (Professional or Home) or Windows 2000 CDROM. (Note: Manufacturers recovery disks generally don't work as they are restore disks, not the original Setup CDROM). Just insert it into your computer and boot from it (check BIOS will enable this feature or access it from an optional boot menu - usually by F12).
Once the Windows Setup (TEXTMODE) is loading, press "R" to launch the Recovery Console which will do so once the setup files are read from the CD. (The other method to get into the recovery console without the CD is to load it from the boot menu, which has to be installed in the first place - see below.)
--------------------------------------------------------------------------------
To restore a restore point in the recovery console:
Type the following:
1. CD c:\
2. cd "system volume information\_resto~1"
3. DIR (this lists restore points)
4. Pick a restore point using folder dates to guide you.
5. CD RPx (x being restore point number to use)
6. CD SNAPSHOT (this takes you into the folder containing all snapshot files)
7. Copy the Registry backups in the restore point and overwrite them to the C:\
COPY _Registry_machine_system c:\Windows\System32\Config\System
COPY _Registry_machine_software c:\Windows\System32\Config\Software
COPY _Registry_machine_sam c:\Windows\System32\Config\Sam
COPY _Registry_machine_security c:\Windows\System32\Config\Security
COPY _Registry_user_.default c:\Windows\System32\Config\Default
8. Type "exit" to leave recovery console and reboot machine.
--------------------------------------------------------------------------------
Available commands for the Recovery Console:
Attrib changes attributes on one file or subdirectory;
Batch executes commands that you specify in the text file, Inputfile. Outputfile holds the output of the commands. If you omit the Outputfile parameter, output appears on the screen;
Bootcfg modifies the Boot.ini file for boot configuration and recovery;
CD (Change directory) operates only in the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources;
Chkdsk The /p switch runs Chkdsk even if the drive is not flagged as dirty. The /r switch locates bad sectors and recovers readable information. This switch implies /p. Chkdsk requires Autochk. Chkdsk automatically looks for Autochk.exe in the startup folder. If Chkdsk cannot find the file in the startup folder, it looks for the Windows XP Setup CD-ROM. If Chkdsk cannot find the installation CD-ROM, Chkdsk prompts the user for the location of Autochk.exe;
Cls clears the screen.
Copy copies one file to a target location. By default, the target cannot be removable media, and you cannot use wildcard characters. Copying a compressed file from the Windows 2000/XP Setup CD-ROM automatically decompresses the file;
Del (Delete) deletes one file. Operates within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources. By default, you cannot use wildcard characters;
Dir displays a list of all files, including hidden and system files;
Disable disables a Windows system service or driver. The variable service_or_driver is the name of the service or driver that you want to disable. When you use this command to disable a service, the command displays the service's original startup type before it changes the type to SERVICE_DISABLED. Note the original startup type so that you can use the enable command to restart the service;
Diskpart manages partitions on hard disk volumes. The /add option creates a new partition. The /delete option deletes an existing partition. The variable device is the device name for a new partition (such as \device\harddisk0). The variable drive is the drive letter for a partition that you are deleting (for example, D). Partition is the partition-based name for a partition that you are deleting, (for example: \device\harddisk0\partition1) and can be used instead of the drive variable. The variable size is the size, in megabytes, of a new partition;
Enable enables a Windows system service or driver. The variable service_or_driver is the name of the service or driver that you want to enable, and start_type is the startup type for an enabled service. The startup type uses one of the following formats:
SERVICE_BOOT_START
SERVICE_SYSTEM_START
SERVICE_AUTO_START
SERVICE_DEMAND_START
Exit quits the Recovery Console, and then restarts the computer;
Expand expands a compressed file. The variable source is the file that you want to expand. By default, you cannot use wildcard characters. The variable destination is the directory for the new file. By default, the destination cannot be removable media and cannot be read-only. You can use the attrib command to remove the read-only attribute from the destination directory. The option /f:filespec is required if the source contains more than one file. This option permits wildcard characters. The /y switch disables the overwrite confirmation prompt. The /d switch specifies that the files will not be expanded and displays a directory of the files in the source;
Fixboot writes a new startup sector on the system partition;
Fixmbr repairs the startup partition's master boot code. The variable device is an optional name that specifies the device that requires a new Master Boot Record. Omit this variable when the target is the startup device;
Format formats a disk. The /q switch performs a quick format. The /fs switch specifies the file system;
Help If you do not use the command variable to specify a command, help lists all the commands that the Recovery Console supports;
Listsvc displays all available services and drivers on the computer;
Logon displays detected installations of Windows and requests the local Administrator password for those installations. Use this command to move to another installation or subdirectory;
Map displays currently active device mappings. Include the arc option to specify the use of Advanced RISC Computing (ARC) paths (the format for Boot.ini) instead of Windows device paths;
MD (Make directory) operates only within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources;
More/Type displays the specified text file on screen;
Rd (Remove directory) operates only within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources;
Ren (Rename) operates only within the system directories of the current Windows installation, removable media, the root directory of any hard disk partition, or the local installation sources. You cannot specify a new drive or path as the target;
Set displays and sets the Recovery Console environment variables;
Systemroot sets the current directory to %SystemRoot%.
--------------------------------------------------------------------------------
Recovery Console Rules
Several environment rules are in effect while you are working in the Recovery Console.
Type set to see the current environment. By default, these are the rules:
AllowAllPaths = FALSE prevents access to directories and subdirectories outside the system installation that you selected when you entered the Recovery Console.
AllowRemovableMedia = FALSE prevents access to removable media as a target for copied files.
AllowWildCards = FALSE prevents wildcard support for commands such as copy and del.
NoCopyPrompt = FALSE means that you are prompted by the Recovery Console for confirmation when overwriting an existing file.
When running the Windows Recovery Console, allow it to start in full admin mode (allows file copy which is disabled by default):
To do so, in Windows you need to run gpedit.msc go to:
Computer Config->Windows Settings->Security Settings->Local Policies ->Security Options
Enable "Recovery console: Allow floppy copy and and access to all drives and folders".
Taken from the Windows Tweaks & Hacks page.
--------------------------------------------------------------------------------
To install the Recovery Console in Windows to the Startup Boot Menu:
Insert the Windows XP CD into the CD-ROM drive.
Start->Run.
Type d:\i386\winnt32.exe /cmdcons (where d is the drive letter for the CD-ROM drive).
A Windows Setup Dialog Box appears. The Windows Setup Dialog Box describes the Recovery Console option. To confirm the installation, click Yes.
Restart the computer. The next time that you start your computer, "Microsoft Windows Recovery Console" appears on the startup menu.
To delete the Windows Recovery Console:
Click Start, click My Computer, and then double-click the hard disk where you installed the Recovery Console.
On the Tools menu, click Folder Options, and then click the View tab.
Click Show hidden files and folders, click to clear the Hide protected operating system files check box, and then click OK.
At the root folder, delete the Cmdcons folder and the Cmldr file.
At the root folder, right-click the Boot.ini file, and then click Properties.
Click to clear the Read-only check box, and then click OK.
Open the Boot.ini file in Microsoft Windows Notepad, and remove the entry for the Recovery Console. It looks similar to this:
C:\cmdcons\bootsect.dat="Microsoft Windows Recovery Console" /cmdcons
Save the file and close it.
Taken from the Make Windows more reliable page.
Post a Comment