Minimal Windows

Having Windows Recovery Console is quite useful. However there are many things which cannot be done using the recovery console. Lets say the machine is infected and you need to run a virus scanner from a clean system. In this and many more cases, it will be very useful if one could actually boot into a working copy of Windows off the CD, which does not even require a hard disk to be present. In short, what we want is a Knoppix for Windows.

One solution is cough up a lot of dough and buy the Windows Pre-execution Environment (WinPE) from Microsoft. Even if you are willing to do just that, you may not be eligible to do that. This is where BartPE comes to the rescue. It is a freely downloadable piece of windows software, which allows you create such a CD, using your original Windows CDROM. See BartPE documentation on how to create such a CD.

Making BartPE, isolinux and Windows Recovery console co-exist

Each one requires the use of the I386 directory to store its files. BartPE requires additional directories, but they are not an issue. Since the contents of the I386 directory is different for RC (Recovery Console) and BartPE, one needs a way around this requirement.

  1. Use PEbuilder to generate the files you need in directory PE. It will contain a few files at the top level, and directories I386, Programs...
  2. Assume you already have the contents of the ISOLINUX CD prepared in the directory CDROOT.
  3. Neither one of CDROOT and PE is a child of the other
  4. Assume you already have RC in CDROOT (see here for details). So you will already have a CDROOT/I386, CDROOT/isolinux among others.
  5. Make a copy of the xp bootsector (which you used for RC) and call it, xppesect.bin. Place this also in the CDROOT/isolinux directory. Replace all occurences of I386 in xppesect.bin with XPPE. Similarly replace all occurences of I386 in PE/I386/setupldr.bin with XPPE (A python script for the above is available in the downloads section).
  6. Rename you PE/I386 directory as PE/XPPE. Rename all files within PE/XPPE to their uppercase versions (so MyFileName.Ext becomes MYFILENAME.EXT) recursively (A shell script for the same is also available in the downloads section).
  7. Now copy PE/XPPE, PE/Programs and any other subdirectories of PE to CDROOT. Also copy the WIN51*.* and WINBOM.INI to CDROOT and uppercase their names. If any of these files are already present in CDROOT (created for RC), then you may use either one (only the name of the file matters, the contents dont).
  8. You will need a new version of mkisofs which supports iso-level 4 (you might have to settle for an alpha version of mkisofs for that). Finally run mkisofs as follows
            mkisofs -o mycd.iso -b isolinux/isolinux.bin -c isolinux/boot.cat 
            -no-emul-boot -boot-load-size 4 -allow-lowercase -output-charset cp437 
            -r -iso-level 4 -boot-info-table CDROOT
    	

murali krishnan GANAPATHY
Last modified: Wed Nov 13 15:45:40 CST 2002