14 August 2012

How to install and run a full winxp on usb disk

Winxp is really a good member of windows family. It is maybe the most common version of windows has ever used until now. This post will show you how to put a full winxp on usb disk to use it anywhere.

Requirement :

  • Ability to use some VirtualMachine Management like VirtualBox, VMware, ... 
  • Good knowledge at using Winxp. 

Terminology :

  • Vhd file : It looks like an image of a disk (and partitions) inside. 
  • WinVBlock : Virtual scsi driver for Winxp to mount vhd disk image. 
  • NTloader : Boot loader of Windows works with ntldr file. 
  • Grub4Dos : Boot loader used to map vhd disk image file. 

Primary steps :

  1. Create .vhd disk image includes a running Winxp (with WinVblock driver installed). 
  2. Make USB disk bootable with NTloader and Grub4Dos. 
  3. Boot the image by Grub4Dos. 

Steps in detail :

1. Create .vhd disk image includes Winxp (with WinVblock driver installed)

1.1 Create New Machine :

In this post we will use VirtualBox to make an Winxp virtual machine with vhd disk image (fixed-size harddisk) (2GB for example) in vhd format. Notice to use fixed-size hard disk, otherwise Grub4Dos won't work !

 

Point the CDROM drive to an Winxp installation disc (.iso), and install it as usual till it finishes.


1.2 Disable Page File :

By default Winxp uses a page-file (double RAM size) on the C: drive, it takes alot of disk space. We don't need it, so we will remove it, and a full Winxp will takes about 900MB in size.


1.3 Config the Winxp driver to make it works on all machine :

Because our Winxp will run on USB disk, we need to make it able to run on all of different machine without depend on the driver (independent with driver) by making some devices using Standard Driver.

Open the Device Manger and update : IDE ATA/ATAPI Controllers and System Devices to use
Standard driver. In this case, they should use :
  • IDE ATA/ATAPI Controller :
    • Standard Dual Channel PCI IDE Controller. 
  • System Devices : 
    • PCI bus. 
    • PCI standard host CPU bridge. 
    • PCI standard ISA bridge. 


Reboot the virtual machine if necessary, and you should have a status like this after all :

1.4 Install WinVblock driver :

Google and download the WinVblock driver (or you can download a copy here : https://drive.google.com/file/d/0B3OvTrPZEcO9MTZzVGxVekpqR00/edit?usp=sharing), unzip it. Open Control Panel / Add Hardware. Follow the Wizard and point it to the WinVblock driver folder.

After reboot the Winxp vitual machine, It should have 2 more scsi devices like this.


1.5 Defragment the C drive :

In order to boot with Grub4Dos (map to file), the image file need to be in contiguous disk area.
Just have a check if the C: drive has been fragmented ? If does, open the My Computer, right click on C: drive / Properties / Tools / Defragment Now ...


1.6 Locate the vhd file :

Until now, you should have a running Winxp virtual machine includes :
  • WinVBlock driver. 
  • Some devices with Standard driver (IDE controller and system devices) 
  • C: drive not fragmented. 
Shutdown the virtual machine and locate for the .vhd file (check the Preferences of VirtualBox to find out the default location).