10.4 Advanced Topics

The solutions in this final section of this chapter include the odds and ends that round off the discussion of installing and upgrading Windows XP. If you want to use more than one operating system on your computer, try setting up a dual-boot system, as described later. If you wish to repair a broken Windows XP installation, see "Creating a Boot Disk" and "Using the Windows Recovery Console," both later in this section. Finally, the controversial Product Activation feature in Windows XP is uncovered and explained.

10.4.1 Setting Up a Dual-Boot System

With a dual-boot (or multi-boot) setup, you can install multiple operating systems side-by-side on the same computer, and simply choose which one to use each time you boot. So, why would you want to do this?

  • If you rely on some software or hardware that will not operate in Windows XP, you can install Windows XP and the other OS on the same system simultaneously. This includes any previous version of Windows, as well as Linux, FreeBSD, Unix, BeOS, and even NeXTStep.

  • If you're in the process of upgrading from an earlier version of Windows to Windows XP, you may wish to set up a dual-boot system. That way, you can test XP with your existing software and hardware without having to commit to the new OS until you're certain it will meet your needs.

  • Some people install two copies of Windows XP on their system, one for normal use, and one as a testbed for new software and hardware. That way, you can try out a potentially buggy product without jeopardizing the main OS on which you must rely.

  • Software developers often have several versions of Windows on the same machine so that they can test out their products on a variety of configurations without having to purchase a bunch of separate computers.

Windows XP comes with support for a dual-boot system built-in. The dual-boot feature (called the Boot Manager) is installed automatically when you install Windows XP. If, at the end of the installation, Windows XP is the only operating system on your computer, it will boot automatically without giving you a choice. Otherwise, you'll see a menu of installed operating systems, from which you can choose the OS you wish to use.

So, if you're installing Windows XP on a system with another OS, such as Windows 98, and you don't replace it with Windows XP (instead, you choose to install it into a different directory or partition), you'll get a dual-boot system without even trying.

In most cases, the boot manager of the last operating system installed is the one that will be used for all operating systems. For this reason, the order in which you install the operating systems is important; for example, it's typically desirable to install older operating systems before newer ones.

Some other operating systems, such as FreeBSD and Windows 2000, have boot managers of their own, and can therefore be installed either before or after XP is installed with little additional fuss. However, those operating systems without their own boot managers, such as Windows 9x/Me, will break the Windows XP boot manager if installed afterwards.

But what if you already have a Windows XP system, and you need to the dual-boot capability to it? Fortunately, there is a way to install other operating systems on top of an existing Windows XP installation, although it takes a little extra preparation.

The following procedure assumes that you already have a working installation of Windows XP:

  1. Each operating system must have its own partition, assuming you have only one hard disk. See "Working with Partitions," earlier in this chapter, for details on resizing drives and adding partitions.

    Note that since resizing partitions can be difficult without the proper third-party tools, you can simply add another hard disk instead of repartitioning your existing drive.

     

    It's actually possible for Windows XP to share a partition with a Windows 9x/Me installation but only if they're installed into different folders. Since they'd share the Program Files folder, though, you'd be opening the door for conflicts and other problems.

     

  2. Create a bootable floppy, as described in the next section. The key is to back up the ntdetect.com, ntldr, and boot.ini files, which are the key to the Windows XP boot manager. See the next section for more information on the boot.ini file.

    You'd also be wise to backup your entire system at this point (see Chapter 6).

  3. Install the other operating system; naturally, the installation procedure will vary, depending on the product you're install. Be extremely careful not to install it into the same folder or partion as the existing copy of Windows XP.

  4. When installation of the other product is complete, try starting the system. In some cases, the other product will have a suitable boot manager, and everything will work fine. If it doesn't, the procedure to repair the Windows XP boot manager depends on the other operating system you've just installed:

    Windows 2000 or Windows NT 4.0

    These earlier versions of Windows NT have boot managers similar to Windows XP's, but they may not work with Windows XP specifically. To repair the boot manager here, just copy the files, ntdetect.com, ntldr, and boot.ini, you backed up in step 2 into the root directory of your boot drive (usually C:\), replacing the older ones that should be there.

    Windows 9x/Me

    Since these DOS-based versions of Windows (see Chapter 1) don't have boot managers of their own, the XP boot manager will be subdued by their installation. Although the files, ntdetect.com, ntldr, and boot.ini, should remain intact after installation, your hard disk's Master Boot Record (MBR) will have to be updated to once again recognize the Windows XP boot manager.

    This is done by starting the Windows Recovery Console (described later in this chapter). Start by issuing the fixmbr command to restore the Windows XP boot manager, and then bootcfg /rebuild to force the boot manager to recognize the newly installed operating system.

    Linux, FreeBSD, and others

    Each of these Unix flavors come with their own boot managers, that, for the most part, appear to be compatible with Windows XP. If in doubt, check the documentation for the specific operating system and version you're installing.

  5. When you're done, create another bootable floppy (repeat step 2), such that you have an up-to-date backup of the boot.ini file.

 

A Word About Filesystems and Dual-Boot

Windows XP supports both the NTFS and FAT32 file systems. If you need to set up a dual-boot machine with Windows 9x/Me and Windows XP, you'll need to use FAT32 on any drives that you want to access from the older Windows, as only Windows 2000, NT, and XP support NTFS.

 

10.4.1.1 Editing the Boot Manager configuration file (boot.ini)

The Windows XP boot manager is responsible for loading Windows XP, and, optionally, allowing you to boot into any other operating systems you may have installed. If you've set up a dual-boot (or multi-boot) system, as described in the previous section, the list of operating systems that is presented when you first turn on your computer is stored in the Boot Manager configuration file (boot.ini).

The boot.ini file is, by default, a hidden file, located in the root directory of your primary partition (usually C:\). If you can't see it, you'll have to configure Explorer to display hidden and system files by going to Control Panel figs/u2192.gif Folder Options figs/u2192.gif View tab, and selecting the Show hidden files and folders option and turning off the Hide protected operating system files option.

 

If you screw up your boot.ini file, Windows XP won't load. Before editing the file directly, make sure to back it up as described in "Create a Backup Floppy," later in this chapter, so it can be easily restored if necessary. If worse comes to worse, start the Windows Recovery Console (discussed later in this chapter) and issue the bootcfg /rebuild command to delete and then rebuild the boot.ini file.

 

The structure of boot.ini, similar to other .ini files, is explained in Section 3.2.4. You can view and modify boot.ini in any plain-text editor, such as Notepad. A typical boot.ini file is shown in Example 10-1.

Example 10-1. The Boot Manager configuration file (boot.ini) is used to define the operating systems available in the boot menu
[boot loader] timeout=20 default=multi(0)disk(0)rdisk(0)partition(2)\WINDOWS [operating systems] multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Windows XP Pro" /fastdetect multi(0)disk(0)rdisk(0)partition(3)\WINNT="Windows 2000 Pro" /fastdetect C:\="Microsoft Windows Me" 

The two sections of the boot.ini file are as follows:

[boot loader]

This section determines the default operating system loaded automatically if no selection is made and the timout, the amount of time (in seconds) the Boot Manager waits before said selection is made.

[operating systems]

This section lists each of the individual operating systems installed on the computer. The syntax is fairly simple: a "pointer" to the drive and folder containing the operating system is shown to the left of the equals sign, and the caption shown in the boot menu is shown to the right.

The aforementioned pointer can appear in one of several different ways. The first two entries shown in Example 10-1 point to Windows NT installations (XP and 2000, respectively); the numbers in parentheses specify the disk and volume numbers of the respective partition, followed by the folder in which Windows is installed. The third entry points to a DOS partition (Windows Me in this case), where the syntax is merely the drive letter of the volume containing the OS.

You'll notice that one of these entries matches the value of the default entry in the [boot loader] section.

To change the default OS and the timeout without editing boot.ini directly, go to Control Panel figs/u2192.gif System, and click Settings in the Startup and Recovery section. Unfortunately, if you want to rename one or more of the captions in the menu, you'll have to open boot.ini and change the text in the quotation marks.

See Section 10.4.4, later in this chapter, for additional tools you can used to repair a damaged Windows XP installation and rebuild the boot.ini file.

10.4.2 Creating a Bootup Floppy

Long gone are the days when an entire operating system can be fit on a single floppy diskette. Actually, many would argue that the floppy drive is essentially obsolete, with no real purpose in a modern computer, at least as long as there a network connection or CD writer is available to transfer files. However, from time to time, a floppy can still prove useful.

In some earlier versions of Windows (e.g., Windows 9x/Me), there was a built-in feature for making a bootable floppy, but it only installed a few files on a blank disk that essentially allowed you to boot into DOS and then start or repair the Windows installation on your hard disk. Being able to boot off a floppy also meant that you could access your files if Windows wouldn't start at all.

Now, if you have a bootable floppy made on a Windows 9x/Me system, you can use it to boot any modern system, even if it is running Windows XP. However, if your hard disk uses the NTFS file system (discussed in Chapter 5), you won't be able to access your from from the DOS floppy (since NTFS isn't supported in those versions of Windows). And even if you're still using the FAT32 file system, which will be readable fom a Windows 9x/Me boot disk, you won't be able to start Windows XP or affect any substantial repairs from such a floppy.

Essentially, if you've become accustomed to being able to boot to DOS in earlier versions of Windows, you'll have to adjust your strategy, but that doesn't mean you'll have to live without any safety net at all. There are several ways in Windows XP to fill the holes left by the absense of DOS:

Running old programs

One reason to use a boot disk in the early days was to run old DOS software that refused to operate from within Windows. Although this is no longer practical in Windows XP, you can run any such software in "compatibility mode" (discussed in Chapter 6). Another way to access old software that won't run in Windows XP is to set up a dual-boot system, in the previous section.

Repairing Windows

The best way to repair a Windows installation that won't start is to use the Windows Recovery Console, at the end of this chapter. See Chapter 6 for more troubleshooting tips.

Installing Windows

Since Windows XP comes on a bootable CD, you don't need a floppy to install it. Details can be found at the beginning of this chapter.

Accessing files

If you can't start Windows, and attempts to repair it have failed, you'll still need to access your personal files. Installing Windows XP in a second directory is probably your best bet here. See "Setting up a dual-boot system," earlier in this chapter, for instructions.

Now that I've effectively talked you out of creating a bootable floppy in Windows XP, I'll show you how it's done:

  1. Obtain a blank diskette, and insert it into your floppy drive. Floppies can typically be found behind file cabinets, under desks, and at the bottom of "junk" drawers.

  2. If you haven't done so already, you'll need to configure Explorer to show your hidden and system files. Go to Control Panel figs/u2192.gif Folder Options figs/u2192.gif View tab, and select Show hidden files and folders. Next, turn off the Hide protected operating system files option, and click OK when you're done.

  3. Open Windows Explorer, and navigate to the root directory of your boot drive (usually C:\).

  4. Copy the following three files from this folder to your floppy (usually A:\): ntdetect.com, ntldr, and boot.ini.[14]

    [14] See "Setting up a dual-boot system," earlier in this chapter, for details on the boot.ini file.

  5. Close Explorer and eject the floppy when you're done.

This bootable floppy can be used to boot Windows XP (in some cases) when it's not able to boot itself. It won't get you to a command prompt, however. To go directly to a command prompt, you'll need to use the Windows Recovery Console instead.

10.4.3 Activating Windows XP

Product Activation is the euphemistic name given to the new system in Windows XP intended to curb software piracy. It effectively requires every Windows XP user to call Microsoft (or connect via the Web) to obtain a long product activation key for each installation of the product. As though the hefty price tag and 25-character CD key on the back of the CD package in previous versions of Windows wasn't enough, most users of Microsoft's latest OS are now required to take an additional step to complete the installation procedure.

If you don't enter the product key within a certain period after installing, Windows XP will expire and subsequently cease to function.[15] In theory, you'll only have to do this once for each computer running Windows XP, but the activation code is just as susceptible to bugs as any other component of Windows.

[15] Depending on your outlook, this may be a blessing in disguise . . .

Here's how activation works:

  1. When Windows XP is installed, the 25-character CD Key printed on the CD sleeve is typed by the user and stored in the Registry. The CD Key distinguishes one end-user license of Windows XP from another.

    Windows then generates a 20-digit product ID based on the CD Key and the Windows version.

  2. After Windows has been installed, the Activate Windows XP utility is started. The "Installation ID," comprised of the 20-digit product ID plus an 8-digit hardware ID, is then transmitted to Microsoft. This is either done transparently over a network connection or manually over the telephone.

    The hardware ID, a unique number based on values obtained from hardware in your computer, distinguishes one computer from another. The hardware ID is based on a hardware hash, a long sequence of numbers based on a information found in your computer's hardware. The specific devices used are as follows:

    1. Display adapter (video card)

    2. SCSI adapter (if available)

    3. IDE adapter

    4. Network adapter MAC address (if available)

    5. RAM amount range

    6. Processor type

    7. Processor serial number[16]

      [16] The processor serial number, in most cases, is not accessible to Windows. See Appendix B for the BIOS setting that affects this.

    8. Hard drive

    9. Hard drive volume serial number

    10. CD-ROM, CD-RW, or DVD-ROM

  3. Microsoft then generates a 42-digit "Confirmation ID," which is sent back to the Activate Windows XP application (or read back verbally if you're activating XP over the phone). The machine is officially activated when the confirmation ID is received, cross-checked with the hardware ID and product ID, and finally stored on your computer.

It should be clear that since the confirmation ID is based upon the unique CD key and the unique hardware ID, it represents a single, unique combination of hardware and software. Change any of these components, and the confirmation ID will no longer be valid.

If you attempt to activate Windows with the same CD Key and a different hardware key (effectively installing the same copy of Windows on a different computer), the copy protection will kick in and the product activation will fail. The gray area is what happens when you ugprade part or all of your system.

Now, there is some margin for error built in, so upgrading only one or two of the aforementioned components should not cause a problem. However, simultaneously upgrading your motherboard, processor, memory, and video card will probably raise a red flag, and you'll probably have to get a new key. Likewise, if you purchase an entirely new computer and install your existing copy of XP on the new machine, you'll certainly have to obtain a new key from Microsoft.

It probably goes without saying that the automated activation will probably fail at this point, meaning that you'll have to speak with a Microsoft representative and explain that you're merely reinstalling and not pirating the software. It remains to be seen how much hassle reactivation will be; suffice it to say that those who upgrade often will bear the brunt of that hassle.

Note that if your system crashes, or if you simply need to wipe everything and reinstall for some reason, the confirmation ID from the previous activation should still be valid. Note that the confirmation ID is only shown if you activated over the phone, and is otherwise invisible; if you used the automated activation over the Internet, all you'll need to do is run the activation again. Since the hardware supposedly is no different, Microsoft shouldn't give you any trouble.

Many users may not be confronted with the hassle of product activation at all, for one of several possible reasons. Those systems purchased with Windows XP preinstalled may be pre-activated as well, in one of two possible ways. Either the manufacturer may choose to activate Windows before shipping using the method described above, or by a separate mechanism called System Locked Pre-installation (SLP). SLP ties the hardware ID to the system BIOS, rather than the discrete components listed earlier. The resulting system may be upgraded more freely, but if the motherboard is replaced or the BIOS is upgraded (see Appendix B), the owner will have to reactivate the software. The other exception is the version of Windows XP sold with a volume license, usually to large businesses, which doesn't include the product activation feature at all.

10.4.4 Using the Windows Recovery Console

The Windows Recovery Console (WRC) is a tool included with Windows XP, used to repair the operating system when it won't start, as well as perform some other tasks not otherwise possible from within Windows.

 

For those accustomed to being able to boot into DOS to effect repairs in some earlier versions of Windows, the WRC is the Windows XP equivalent; see "Creating a Bootup Floppy," earlier in this chapter, for more information.

 

The Windows Recovery Console allows you to do the following:

  • Repair certain parts of a Windows XP installation, including the file system boot sector, the Master Boot Record (MBR), or the Boot Manager configuration

  • Copy, rename, delete, or replace operating system files that otherwise can't be modified while Windows is running.

  • Enable or disable services or devices for the next time Windows is started.

  • Create and format hard drive partitions.

The whole point of the Windows Recovery Console is that it can be started when Windows isn't running. To get into the WRC, start by booting up off the Windows CD, as described in "Installing Windows XP" at the beginning of this chapter. After Setup loads all of its drivers, press R to start the Windows Recovery Console.

You can also install the Recovery Console to your hard disk so that it can be started without the CD. This option, which will add it to the Boot Manager menu (see "Setting up a dual-boot system," earlier in this chapter), is useful if you find that you need the Recovery Console frequently or you're unable to boot off the CD. To install the WRC, go to Start figs/u2192.gif Run and type the following:

d:\i386\winnt32.exe /cmdcons

where d: is the drive letter of your CD drive.

Regardless of how the WRC is started, you'll be greeted with the following friendly welcome message:

Windows NT(TM) Boot Console Command Interpreter. WARNING: This is a limited function command prompt intended only as a system recovery utility for advanced users. Using this utility incorrectly can cause serious system-wide problems that may require you to reinstall Windows to correct them. Type 'exit' to leave the command prompt and reboot the system. 1: C:\WINDOWS 2: D:\WINDOWS 3: E:\WINNT Which Windows installation would you like to logon to (enter to abort)? 

Naturally, the options for your system may be different. Choose 1 here, or whatever number corresponds to the Windows installation you wish to repair, and log in using your Administrator password.

 

If you've forgotten your Administrator password (set when Windows XP was installed), WRC won't let you in. You'll have three tries before WRC reboots your system. If this is the case, and Windows won't start, your best bet is to try one of the other repair options described in "Reinstalling Windows XP," earlier in this chapter.

 

Once you've logged in, the WRC looks and feels like the Windows XP Command Prompt (see Appendix C). However, it's important to realize that it's not exactly the same: for example, you can execute some of the standard DOS commands (albeit in a more limited fashion), but you won't be able to launch DOS or Windows programs.

10.4.4.1 Windows Recovery Console commands

The following DOS commands, documented in Appendix C, can be used in the Windows Recovery Console: attrib, cd, cls, copy, del, dir, exit, md, more, ren, rd, set, and type. In addition, you'll be able to use the chkdsk utility discussed in Chapter 6, the DiskPart utility discussed in "Working with Partitions," earlier in this chapter, as well as the expand, format, and net utilities.[17]

[17] These commands are documented in detail in Windows XP in a Nutshell (O'Reilly).

The following special commands are available in the Windows Recovery Console:

batch filename [ outputfile]

Executes a batch file, where filename is the name of the batch file to run, and outputfile is the name of an optional file into which the output from the job is stored. Note that you can't execute batch files simply by typing the filename, as you can in the real Command Prompt; see the discussion of batch files in Appendix C.

bootcfg / command

Starts the Boot Manager configuration and recovery tool. This tool is used to view, edit, and rebuild the boot.ini file, discussed in "Setting up a Dual-Boot System," earlier in this chapter. The command can be any of the following:

add

Adds a new entry to the boot.ini file.

copy

Creates a backup of the boot.ini configuration file.

default

Sets the default boot entry.

disableredirect

Disables redirection instigated by the redirect command.

list

Displays the entries currently specified in boot.ini.

rebuild

Lists all of the Windows installations and rebuild the boot menu by selectively adding entries. Note: it's a good idea to use bootcfg /copy to create a backup of boot.ini before using rebuild. See "Creating a Dual-Boot System" for a practical example of this command.

redirect [ port baudrate | useBiosSettings]

Enables redirection of the boot loader output to the specified serial port, using the specified baudrate. Alternately, specify bootcfg /redirect useBiosSettings to use the default COM port settings in the system BIOS.

scan

Scans your hard disk for all Windows installations and displays a list of the results. This list is not dependent on the contents of the boot.ini file, but rather on the actual operating systems found on the system. The rebuild command incorporates the scan function.

disable [ service | device_driver]

Disables a system service or a device driver for the next time Windows starts. See enable, below, for details.

enable service | device_driver [ startup_type]

Starts or enables a system service or a device driver for the next time Windows starts. Use the listsvc command to list the names of all available services and device drivers. The startup_type option can be SERVICE_BOOT_START, SERVICE_SYSTEM_START, SERVICE_AUTO_START, or SERVICE_DEMAND_START.

fixboot [ drive]

Writes a new partition boot sector onto the specified partition, where drive is the drive letter. In most cases, you can omit drive to use the current partition. Use this command to fix the partition boot sector if it has been damaged, typically by a virus or the installation of another operating system.

fixmbr [ device]

Repairs the master boot record of the specified disk. Use the map command to display the entries for device. In most cases, you can omit device to use the default boot device, upon which your primary operating system is installed. Use this if the boot record has been damaged, typically by a virus or the installation of another operating system. See "Creating a Dual-Boot System" for a practical example of this command.

listsvc

Lists the services and drivers available on the computer, for use with the enable and disable commands.

logon

Logs on to another Windows XP/2000 installation (assuming you have more than one) without having to reboot and re-enter the Recovery Console. Naturally, you'll need the administrator password for any such installation.

map

Displays the drive letter mappings for use with the fixmbr command.

systemroot

Changes the current directory (like the cd command explained in Appendix C) to the "systemroot" directory of the operating system to which you are currently logged on (usually c:\windows).

10.4.4.2 Lifting Recovery Console restrictions

By default, the attrib, copy, del, dir, and ren commands don't support wildcards (* and ?) when used in the Windows Recovery Console. While this is a safety feature intended to prevent unintentional damage to the system, it can be frustrating to say the least. To lift this restriction, type:

set AllowWildcards = true

Another restriction is one placed on the cd command, where WRC will only allow you to change to certain directories. To fix this, type:

set AllowAllPaths = true

To enable access to the floppy drive, type:

set AllowRemovableMedia = true

Finally, to turn off the prompt that appears when you try to replace a file with the copy command, type

set NoCopyPrompt = true

Unfortunately, these are only temporary settings and are lost as soon as the system is restarted. For more information, see the set command in Appendix C.

 

You may encounter an error to the effect that the Set command is currently disabled; unfortunately, this can olny be fixed by returning to Windows and following this procedure:

 

  1. Start the Local Security Settings editor (secpol.msc).

  2. Navigate to \Security Settings\Local Policies\Security Options in the tree.

  3. Double-click the Recovery Console: Allow floppy copy and access to all drives and all folders entry.

  4. Click Enabled and then click Ok.

  5. Close the Local Security Settings editor when you're done.

  6. Return to the Recovery Console and try again.



Windows XP Annoyances
Fixing Windows XP Annoyances
ISBN: 0596100531
EAN: 2147483647
Year: 2005
Pages: 78
Authors: David A. Karp

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net