Wednesday, September 22, 2010

Installing a Tweaked Version of Windows XP SP3

I was installing Windows XP Professional SP3 (referred to here sometimes as simply WinXP).  I was doing this in a virtual machine (VM) environment, which meant that I could test and retry various steps in the process.  The VM environment (using VMware Workstation 7.1) did not appear to have much if any impact on the actual functioning of Windows.  So the following comments may contain a few notes of interest for VMware users, but should also work for general purposes.

Since I was installing in a virtual environment, I probably avoided some hardware problems that non-virtual setups may encounter.  For example, when installing directly on a system with a Gigabyte motherboard, I had encountered a MarkFun_Load_NT_Driver error.  The solution for that was to make sure the latest Gigabyte drivers were installed and, if that failed, to uninstall the Gigabyte Easy Tune software.  The hardware situation was probably simpler and more stable in the VM environment.

To somewhat simplify the process of installing and upgrading, I was installing from a slipstreamed WinXP SP3 CD.  My plan was to run the installation process from the CD, and then focus on setting up an all-purpose basic WinXP installation.  That is, I would be primarily concerned with settings and adjustments to Windows itself, as distinct from applications and other programs.  So this post describes the steps I took to configure WinXP.

I had recently had a problem in WinXP that I had addressed by getting rid of the user account (i.e., the one with my own name) and keeping only one account, Administrator.  A search had led me to the information that, for security reasons, Microsoft recommended against running the computer as an administrator on a regular basis; they recommended instead making that other user a member of the Power Users group.  A Power User, they said, would still be able to run programs as an administrator to some extent.  But for reasons of convenience, I decided to go ahead and remove the user account:  Start > Run > control userpasswords2.  But In this case, I didn't see my own username.  Possibly VMware Workstation had bypassed that part when it set up the VM from the Windows disc.  So I didn't have to log in as Administrator to delete the user account; there was no such account.

Now that I knew all of my adjustments were going to apply to the same (Administrator) account, I was free to start making them.  First, in a step that I should have taken at this point but did not actually take until later, I installed security software.  I initially went with Panda Cloud and Comodo Firewall, but Panda was malfunctioning.  I also tried Avast, on a different machine, but I found that it interfered with outgoing email sent in Thunderbird Portable.  So I tried again by installing the free version of AVG Antivirus.  I did that first, because it would complain during installation about conflicts if Comodo was already installed.  Then I did install Comodo (firewall only).  I had learned that installing multiple firewalls and antivirus programs could be counterproductive, and was migrating away from the temptation to install other sorts of vaguely security-related programs (e.g., Windows Defender, Spyware Blaster) that did not seem to do much (other than, perhaps, impair performance).  I had the impression that Threatfire was somewhat different -- that it was designed to operate in conjunction with existing antivirus and firewall software -- but it hadn't seemed helpful, in my recent experiments, so I skipped it.

My actual next step was to create a separate 4GB partition for my paging file.  (If I had not been working in a VM, I would have used GParted, provided by itself or on Ubuntu Live CDs at System > Administration > GParted, to create this small additional partition.)  After I created it and booted into WinXP, I went into Start > Run > diskmgmt.msc.  The Initialize and Convert Disk Wizard started up, wanting to make something useful of that unformatted 4GB paging drive.  I went ahead with that and then right-clicked on that partition and went through the New Volume Wizard.  I assigned drive letter P to that 4GB partition and labeled it PAGING.  No compression.  When that was done, I right-clicked on the CD-DVD drive and made it drive Y, and then right-clicked on drive C and labeled it PROGRAMS.

Next, I made changes in Windows Explorer.  First, I arranged its Windows Explorer views and panes to suit me, including its menu bar and status bar.  I right-clicked on its Go button to get rid of that.  Then, in Tools > Folder Options > General Tab, I set classic folders.  In the File Types tab, I scrolled down and selected the REG (Registration Entries) file type, and clicked on Advanced > Merge > Set Default > OK.  In the View tab, I told it to show me system folders, hidden files, extensions, and protected operating system files, but not to show me pop-up descriptions for folder and desktop items.  Finally, I clicked on the Apply to All Folders button.  I went back into Tools > Map Network Drive and assigned drive letters to my VMware network drives (referred to, in that dialog, as VMware Shared Folders).  After finishing with that, I right-clicked on the names of the mapped drives in the left-hand pane, and changed them to the names I preferred.

My drive arrangement included drive C, of course, for Windows programs, and also drive D, for data.  Within drive D, I created D:\Installation, where I saved things that I didn't want to have to recreate, reconfigure, or reorganize after a new Windows installation on drive C.  So now I copied the entire contents of the I386 folder on the Windows XP installation CD to D:\Installation\I386.  (To make sure it went right, there should not be a folder called D:\I386\I386.)  I could have installed WinXP from the hard drive in the first place, but I wasn't sure whether that worked well in the case of a slipstreamed CD.  So instead, at this point I adjusted WinXP so that it would look to the hard drive whenever it needed files from the installation CD.  This would prevent messages like "Files Needed:  The file [filename] on Windows XP Professional Service Pack 3 CD is needed" and "Windows File Protection:  Files that are required for Windows to run properly must be copied to the DLL Cache."  This required a registry edit.  I could have done it manually, using regedit or a tool like Registrar Registry Manager Lite.  Instead, I just ran this registry file, called RegTweak1.reg:

Windows Registry Editor Version 5.00

; ************* TWEAK SOURCES *************
; and other assorted sources.

; ************* NOTES *************
; There are undo options for many of these at the sources (above).
; Items that are commented out were not needed on this system.
; Run this with no other programs running (even Windows Explorer).

; ************* TWEAKS *************

; * * * Specific to a new installation * * * 

; Set online registration as being completed
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]

; Disable Windows Tour 

; Specify source path to WinXP installation files
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]

; Set Control Panel to classic view

After running that, I rebooted.  I did originally have that and the other reg files shown in this post (below) in a single file called Mega.reg.  After I ran it, though, I had lots of issues, and it was hard to nail down what had caused them.  So I went to this three-part approach.

There were hundreds if not thousands of possible tweaks of Windows XP.  Many were listed at sites such as Kellys-Korner, The Elder Geek, and Bob Cerelli's Windows Page.  Others could be created with scripts and .reg files and/or with tools like RegShot, TweakUI, and XQDC X-Setup Pro 9.2.  The reg files shown in this post came from such sources.  Generally, I found that it was possible to find or create working .reg files (incorporated into Mega.reg) for simple changes, and less worthwhile to make the effort for more complicated tweaks.  I had originally included these several registry edits in a larger file that I ran all at once, but that file kept mutating.  Parts of it were proving unnecessary, and parts of it also seemed to be screwing up my installations.  But I left the initial explanatory notes here in RegTweak1.reg for future reference.  Anyway, after running RegTweak1, I rebooted and hit Start > Run > "sfc /scannow."  System File checker ran without requiring me to insert the Windows installation CD, so apparently the tweak worked.  If it had failed, I would have resorted to additional instructions.

Back in Windows Explorer, at the bottom of the file list in the Folders pane, I right-clicked on Recycle Bin > Properties > Global tab > uncheck "Display delete confirmation dialog."  Also, near the bottom of the Folders pane, I made changes in Control Panel.  I started with Control Panel > Add or Remove Programs > Add/Remove Windows Components (on the left side):  turn on Internet Information Services (IIS), turn off Indexing Service, and if there is a land line for phones, turn on Fax Service.

Going down the list in Control Panel, I changed Display, Mouse, and Power.  In Display, I made several changes to suit my preference, and also turned off the Desktop Cleanup Wizard by choosing the Desktop tab > Customize Desktop > uncheck "Run Desktop Cleanup wizard every 60 days."  Then, still in Control Panel, I customized Taskbar and Start Menu and then went into System.  Going down the list of tabs in System, I made sure System Restore was running only on drive C; requested downloads but not installation for automatic updates; set the computer's name; and checked Hardware to verify there were no problems in Device Manager.  Then I made several changes in the Advanced tab, under Performance Settings.  First, on the Visual Effects tab, I deselected the items I didn't need.  (Note:  deselecting the wrong ones could make the video interface look pretty bad.)  Next, in the Advanced tab, I went into Virtual Memory Change.  There, I set "No paging file" for drive C and "Custom size" (minimum 2000, maximum 3800) for drive P.  (I had to click "Set" for each drive separately, else it wouldn't keep the value I had designated.)  I clicked Apply and OK to get out of there, and rebooted.

Next, I moved the contents of the Start Menu folders for all users (C:\Documents and Settings\All Users\Start Menu) and for me specifically (C:\Documents and Settings\Ray Woodcock\Start Menu) to D:\Installation\Start Menu.  I had to copy rather than move some files and folders that didn't want to move.  Then I deleted all but the empty Start Menu folders from the source locations.  I was supposed to set the Hidden attribute for the desktop.ini file in the new Start Menu\Programs\Startup folder to keep it from opening at bootup, but it wouldn't let me, so I deleted it.  I would eventually rearrange the Start Menu considerably, but for now it was somewhat chaotic.  I did make one tweak there now, though.  I right-clicked on the shortcut for Windows Explorer in the Start menu and went into Properties > Target box (not button).  I wanted Windows Explorer to open in drive D, so what I typed in the Target box was %SystemRoot%\explorer.exe /e,"D:\."  Then I ran RegTweak2.reg:

Windows Registry Editor Version 5.00

; * * * Additional useful tweaks * * * 

; Turn off automatic restart after Windows Updates are installed

; Disable automatic reboot after crash so you can see error messages
"AutoReboot "=dword:00000000

; Don't clear paging file at shutdown
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management]

; Remove "Log Off" option from Start Menu

; Disable balloon tips

; Remove Language Bar
; Could also use Control Panel > Regional and Language Options > Languages > Details > Language Bar button > uncheck Show the Language bar on the desktop check box
@="Language bar"

; Increase Start Menu display speed -- default is 400
[HKEY_CURRENT_USER\Control Panel\Desktop]

; List My Computer before My Documents in Windows Explorer

; Disable creation of Thumbs.db

; Double-pane Windows Explorer for network drives
@="[ExploreFolder(\"%l\", %I, %S)]"

; Windows Explorer classic search
"Use Search Asst"="no"

; Disable beep on error
[HKEY_CURRENT_USER\Control Panel\Sound]

; Add "Command Prompt Here" option to context menu
[HKEY_CLASSES_ROOT\Directory\shell\Command Prompt Here]
@="Command &Prompt Here"
[HKEY_CLASSES_ROOT\Directory\shell\Command Prompt Here\command]
@="cmd.exe /k cd %1 "
; ALTERNATIVE:  Command Window
; Context menu command window option
; [HKEY_CLASSES_ROOT\Directory\shell\cmd]
; @="Open Command Window Here"
; [HKEY_CLASSES_ROOT\Directory\shell\cmd\command]
; @="cmd.exe /k \"cd %L\""

; Add Copy To and Move To to context menu
[HKEY_CLASSES_ROOT\AllFilesystemObjects\shellex\ContextMenuHandlers\Copy To]
[HKEY_CLASSES_ROOT\AllFilesystemObjects\shellex\ContextMenuHandlers\Move To]

; Disable context menu Send To
[HKEY_CLASSES_ROOT\AllFilesystemObjects\shellex\ContextMenuHandlers\Send To]

; Files with no extension open in Notepad
@="Open With Notepad"
@="notepad.exe %1"

; Disable XP from asking "Do you want to open this file?"
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Download] 

; Turn off Auto-Play for removable devices
; ALTERNATE:  "NoDriveTypeAutoRun"=dword:000000FF

; Disable CD autorun

While I was doing this, XP had been downloading updates.  So instead of rebooting, I went with the Turn Off option, allowing it to install those updates and shut down.  I made a backup of the installation so far.  This involved setting a System Restore point and doing an Acronis drive image backup.  Then I continued with the process.  I went to the Windows Update webpage and, using the Custom option, downloaded all of the remaining updates they had.  I reran and rebooted and reran until there were no more updates to be had.  The only download I rejected was Windows Search 4.0, and that was because I planned to try Copernic instead.

(Recent experience had demonstrated the importance of making sure that updates were installed:  the situation could get worse if left unaddressed.  Steps to be taken in such a case included rebooting and trying again; confirming that there were no errors in the "Review your update history" option at the left side of the Windows Update webpage, and clicking on the question mark next to the red X for any failed items; consulting Control Panel > Add or Remove Programs > Show Updates to see if the offending item had been installed but could be removed and reinstalled; and searching Microsoft support for the KB item and error code.  In my most recent experience, involving a .NET framework error, the .NET Framework Cleanup Tool provided the apparent solution.  Fortunately, this time around, I had no such problems.)

While I was in Internet Explorer (IE), I went to Tools > Internet Options > Security tab > Trusted Sites > Custom Level.  Near the bottom of this list, right before the Scripting section, I changed "Websites in less privileged web content zone can navigate into this zone" away from Prompt, to either Enable or Disable.  Also in the Security tab, I went into Local intranet > Sites > uncheck Automatic and checked all three "Include all" boxes.  Elsewhere in IE, I went to the Programs tab and named Hotmail as my default email program.  I clicked Apply > OK.  Then I navigated to and played a video, so as to trigger the process of installing Adobe Flash Player.  (I could also have gone into Tools > Internet Options > General tab > Browsing History > Settings to move the Temporary Internet Files to another drive, but for some reason this was not working in my VM setup.)  Then I ran RegTweak3.reg and rebooted:

Windows Registry Editor Version 5.00
; * * * Miscellaneous Tweaks * * *
; Skip logon screen
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
; Eliminate "Windows cannot open this file" message
; Use these lines to undo
; [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer]
; "NoInternetOpenWith"=-
; [HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer]
; "NoInternetOpenWith"=-
; Set locations for Start Menu and special folders
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders]
"My Music"="D:\\Current"
"My Video"="D:\\Current"
"My Pictures"="D:\\Current"
"Start Menu"="D:\\Installation\\Start Menu"
"Programs"="D:\\Installation\\Start Menu\\Programs"
"Startup"="D:\\Installation\\Start Menu\\Programs\\Startup"
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders]
"My Music"="D:\\Current"
"My Video"="D:\\Current"
"My Pictures"="D:\\Current"
"Start Menu"="D:\\Installation\\Start Menu"
"Programs"="D:\\Installation\\Start Menu\\Programs"
"Startup"="D:\\Installation\\Start Menu\\Programs\\Startup"
"Administrative Tools"="D:\\Installation\\Start Menu\\Programs\\Miscellany\\Administrative Tools" 
"Cache"="E:\\Cache\\Temporary Internet Files"
; Increase no. of remembered folder sizes to 5000; max of 8000 = 00001f40
"BagMRU Size"=dword:00001388
"BagMRU Size"=dword:00001388
; Save settings on exit
; * * * Internet Explorer and Online
; Specify IE download directory
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer]
"Download Directory"="D:\\Current"
; Force IE to launch shortcuts in a new window
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main]
; Disable Microsoft and Internet Explorer error reporting
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main]
; Increase Internet download connections to 10
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
; * * * Bug Fixes * * *
; Increase number of Page Table entries - prevent USB delayed write error
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management]

Now it was time to install some programs that were designed to tweak various aspects of the system, and especially of the user interface.  Having already gone through X-Setup and others mentioned above, I was looking for more targeted, single-purpose programs here.  One was the Clear Type Tuner, to improve readability onscreen -- although, in my case, the bad video I was getting seemed to come from my use of a VGA cable rather than a DVI cable to connect my monitor to the computer.  Others included TClockEx, Taskswitch PowerToy, VisualTaskTips, FileBox eXtender, and Unlocker 1.8.5 (no Bing bar).  Some of these were familiar; some were new to me.  I also installed Bullzip PDF Printer.  These were in addition to the portable utilities I had available on the hard drive.

I noticed at this point that the system was running slowly, so I installed Advanced WindowsCare (precursor to Advanced SystemCare), ran and reran its first four items, and then rebooted.  I ran it again, this time also including its junk file cleaner, and put a shortcut to it in my Startup folder.  It seemed to help.  There was another problem, though, involving the failure of Windows Explorer to remember when I tried to cut and paste multiple files.  I have addressed that problem in a separate post.  I also set up my Start Menu.  As described in another post, I set it up to be portable -- that is, to be on drive D, to refer to default program locations on drive C, and to include portable apps.

Next, I wanted to test some of what I had installed.  Using portable versions of the applications, I opened a .doc file in OpenOffice Writer, an .xls file in OpenOffice Calc, a .pdf in Sumatra, and a .wav file and a .jpg in IrfanView.  I also opened the .wav in its default application, which at that point was Windows Media Player, and this generated the process of validating Windows and going through the other steps necessary for WMP to run.  These all worked OK.

This was the end of this effort to log the steps required to install one variety of a tweaked Windows XP installation.  I expected to continue to refine it and, eventually, to update it to a later version of Windows.



Later, I found that Filebox Extender was incompatible with AvaFind. The latter was the best file-finder available, in my experience, so I gave Filebox Extender the boot.


New discovery: to create a shorthand reference to a program, copy the shortcut to C:\Windows. For example, I wanted to be able to refer to FirefoxPortable.exe in a batch command. I created a shortcut, named it Firefox, and put it in C:\Windows. Now, when my batch file refers to "Firefox," that .exe runs.

Thanks to for this one.