March 2009
From Linux, wipe out the boot sector, either with shred: shred -n10 -s5M -z /dev/sda or with dd: dd if=/dev/zero of=/dev/sda bs=512 count=2000.
Note | |
---|---|
I don't know how to do this from DOS or Windows. The point is that no previous bootloader/partition table/filesystem should be recognizable on the system, or Windows may just decide not to boot later on. |
Use a boot image with GDisk
to partition.
As of this writing, the available GDisk boot images will partition the disk into a primary C:-drive of type fat32 with LBA on, and an extended/logical (equal size) D:-drive of type fat32, but with the LBA setting omitted.
There is a choice between 20, 30 or 40GB used for the C:-partition.
For future-proofing, pick the 40GB.
Note | |
---|---|
The unattended Windows XP installer fails without notice on partitions created with Linux tools (parted, fdisk, sfdisk), unless they closely mimick the idiosyncracies of GDisk. There would be a point in trying to do just that to shorten the installation sequence, but for simplicity, just use GDisk. |
Start the unattended installer of XP, and let it run to the point where it reboots for the first time.
Note | |
---|---|
There is no problem in letting the XP install finish. It's just that it's a waste of time now. |
Boot into a diskless Linux. (The entry LiveDistros->32-bit in the Osis boot menu will work for now, later this step can be automated away on a boot image as has been done with GDisk.) Fetch the script partitioner.sh and run it: bash ./partitioner.sh -x (run it with -h option to see more possible command line parameters). This will leave the C:-drive alone, but remove the D:-drive and replace it with an empty extended partition for the LWP, and then re-create a smaller, empty D:-drive.
Warning | |
---|---|
Be aware that even with the volume name properly set on the first partition, the XP unattended install will run, but fail to reboot. The exact reason/cause for this is unknown to me, my rule is: in order to install XP, GDisk must be used for creating the first partition. Please send in intelligence. |
Run the unattended installer of the LWP.
Try to boot into both Windows and Linux if you want.