Jump to content

Xen Virtualisation and Windows XP


ianw1974
 Share

Recommended Posts

Since my nice new install of CentOS 5.2, I've installed Xen Virtualisation and have been playing about with this for the last few days. I wrote up my experiences so far with Xen here:

 

Installing Xen Virtualisation with a Windows XP Virtual Machine

 

I'm looking forward to trying para-virtualisation in the near future - I just need some spare hardware where I can start using physical or LVM partitions to see how speedy it really is. According to what I've read, it is almost native speed :)

 

A shame fully virtualised isn't though, but it's still not bad in terms of performance - but I think this is down to using an image file, instead of a physical partition. My article explains a bit more about this.

Link to comment
Share on other sites

  • 1 month later...

Just wanted to add, that if you use the kvm module in the kernel, you can improve the Windows performance to near native speed. Under CentOS at least the two packages required are kmod-kvm and kvm which give you the kernel module. Then just:

 

modprobe kvm-intel

 

or

 

modprobe kvm-amd

 

for whichever processor you have, and you'll find Windows is very very fast indeed. I've yet to see if it's any faster than Windows running under VMware, but so far it seems to be from the installation process at least. Package names will vary from distro to distro, you just need to find the one that has the kernel module unless of course it already exists in the kernel you have installed.

Link to comment
Share on other sites

That's an interesting way to do it. Although using VMplayer, but at least I can more or less create the machine with VMware Server 1.x and then edit and modify the rest of the hard disk settings accordingly. Although I'm wondering if he is requiring the copy of the MBR to put in place later, as I have a feeling that when you try to install to an empty partition, the MBR won't be installed, and thus perhaps Windows won't start. He already had an installation so he took the MBR and dumped it to a file to use later.

 

Would have to check this to see if a clean installation would boot, but I have a feeling it won't. I had the same problem originally when I tried to install Windows through Xen to /dev/sda1 on my laptop, it never booted after install - presumably the MBR problem as I'm unable to do it now to check again to be sure.

Link to comment
Share on other sites

I've been running CentOS for while now too, started with 5.1 now upgraded to 5.2. Really like it, and I'll run it for years without needing to reinstall. Nice article you wrote, but you don't make this clear...

 

I haven't tried yet to tackle setting up true XEN para-visualization as it looks to be some work, but from what I know about it it should really be good. I'll get around to it sometime. Anyway, maybe I'm wrong but far as I can tell, if you use 'full visualization' (i.e. QMEU + image file) you're not really using XEN as such, just QMEU. XEN only kicks in using 'para-visualization' (XEN kernel + LVM or a physical partition). I tried full visualization, but went back to running Win4LInPro 5.0 (basically a customized QMEU) as it's much simpler to configure and use than 'plain' QMEU and just as fast or faster.

 

Regarding allocating memory under QMEU, rather than allocating more memory, best performance is usually achieved by using less. So allocate as little as you can get away with. Running Win2kPro I only use 128-256MB. Setting 1G really slows things down noticably. XP is a hog compared to Win2k and will need at least 256MB, maybe 512 depending on what apps you use, 1G rarely. Use Win2kPro if at all possible with minimal memory and QMEU will run it near-native speed, except, as you mentioned, disk I/O isn't real good.

 

Also, I see your laptop has 4G of memory. Don't you need to run a PAE kernel for all the RAM to be recognized?

Link to comment
Share on other sites

Ian, be assured that this VMWare setup does work. I did it (maybe my post isn't clear about that). Windows does boot from the real MBR on the real hardware, and it also does boot from the fake MBR, linked to the real partition, inside the fake machine (VMWare) :D

 

Unfortunately, amusing as it may be, it is simply useless, because of this activation thing :(

I registered my work's XP again after booting inside VMWare, and it worked (without registering, it wouldn't work). Next reboot from the real hardware, I had to register XP again, and I decided it was the end of the game. If I understand correctly (I never had my own Windows), you can register only a limited number of times, and I can't afford to trash my job's XP license.

 

Solution: instead of using Windows only a little (with VMWare), I don't use Windows at all! :P

 

Yves.

Link to comment
Share on other sites

I've only activated mine a few times I think. However, I would argue that activation point with Microsoft. I paid near 300 GBP for Windows XP when it first came out, and if I want to use it I sure as hell want an activation code :)

 

Of course, rebooting and having to re-activate it again is a bit alarming though.

Link to comment
Share on other sites

  • 5 months later...

I've since found that para-virtualisation drivers can be found for Windows, which means you should be able to run the machines much faster. I have to check this out :)

 

Windows and Para-Virtualised Drivers

Link to comment
Share on other sites

Yes, it worked :)

 

Windows XP installed on my Quad Core, with a machine allocated with 1GB of RAM and 20GB disk via an LVM volume in 17 minutes! Hardware of course is important, so perhaps my previous machine, eg: laptop with 160GB disk and 4GB of ram was not so good - at least perhaps disk performance let it down. My desktop has disks with 32MB cache. Also, after I installed the para-virtualised Windows drivers, the machine seemed to be a lot better indeed!

 

Article updated here: Installing Xen Virtualisation with a Windows XP Virtual Machine.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...