I had offered a talk on this to PACS but the procedure I for Virtualizing windows on Linux also provides clean way of imaging a Windows box which is especially critical to protection from Ransomware. Since the image is portable it is valid for virtualization use as well as bare metal installations.
The high level points are that you need two tools:
1) qemu-img (Linux)
2) sysprep (Windows)
You will also need a storage location to store the file the VM file that is produced.
Fortunately for WinXP the procedure might be slightly less complicated. I'll give you all the steps first and then point out where you might save time.
- Boot into Windows and use sysprep to create an out-of-box-experience - open a command prompt, sysprep from the system32\sysprep folder of your $systemroot (which is normally c:\windows. When the dialog box comes up choose the one say says "OOBE". You should also check "Generalize". For "Shutdown Options" you should choose "Shutdown". The first time you do this you should not get any errors. Sequent runs however will require setting setting two registry keys which reset the OOBE counter. I don't have that in front of me right now but its out there on the internet of I can email you the .reg file I created to do this.
- Boot into a Linux live cd with qemu-img to create the VM disk file - This is a matter of preferent but in my case, I have usb flash and hd installs of Lubuntu and Slax that I use. As long as you have network access you use whatever you want and then get a repository package that has the qemu-img program. In the Ubuntu world that is "qemu-utils". You will need to have the storage location for the VM image available. The most time efficient way to do this is by connecting a USB drive with enough space but you also stream this over the network to a location as well (i.e. via SSH). Keep in mind that this is the slowest part of the process. There are ways to be accelerate that I will mention later. This is also space intensive and will consume at least the amount of space you have in use on your file systems.
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
Keith C. Perry, MS E.E.
From: "Eric H. Johnson" <ejohnson@camalytics.com>
To: "Philadelphia Linux User's Group Discussion List" <plug@lists.phillylinux.org>
Sent: Sunday, June 7, 2015 11:53:51 AM
Subject: [PLUG] Virtualize a bare metal machine
Hi all,
I have an old computer and install that is to be retired but would like to preserve the machine as it is as a VM, just in case it ever has to be ressurected. The OS is Windows XP and the primary application talks to a serial port, which I believe at least VirtualBox does virtualize properly. The hard drive is only 160GB and no more than 30-40 GB is actually in use.
I know of a number of tools where I can do this for Linux, but is there a tool that will let me backup / virtualize a bare metal install of WinXP? There is windows backup, which I guess I could backup and then restore to a freshly created VM. (I think that exists back in XP).
Any other ideas?
Thanks,
Eric
___________________________________________________________________________
Philadelphia Linux Users Group -- http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug