Showing posts with label troubleshooting. Show all posts
Showing posts with label troubleshooting. Show all posts

Friday, March 30, 2012

How to configure Virtio or e1000 1G NIC in Windows XP KVM Guest

By default kvm uses 10/100M NIC. What is good in it windows recognize it out of the box. It means no hassle with drivers and internet connection is available after guest installation is done. Default NIC is fine for browsing but if you need to transfer 0.5G installation for testing into guest OS several times a day it is time pit, because download takes about half an hour.

There are many options to consider:

  • using .iso file and mount it as CDROM,
  • try to use USB device,
  • configure kvm to provide 1G NIC for guest

All options have pros and cons not explained here. At first sight I thought last options is simple, but it took time to figure out right kvm options to get it works and have pretty decent download speed.

It seems simple :) just read what

man kvm

says. Then check what NIC models are supported with

kvm -net nic,model=?

and follow instructions, but there are several tricks to do before you success:

  • 1. You need to find drivers for Virtio or e1000
  • 2. Just using -net nic,model=e1000 in kvm parameters is not gonna work even after driver is installed, because it requires -net user option as well
  • 3. Your CPU should be powerful enough to emulate 1G download for NIC

So lets assume there are Windows XP installation disk iso image at /images/winxp.iso, windows guest installed on your desktop in /guests/winxp.img and it works with usual parameters like

kvm -localtime -m 2047 -soundhw all -boot d -cdrom /images/winxp.iso /guests/winxp.img -vga cirrus -cpu host

First you need to download drivers. Start your Windows guest with default NIC and download Virtio driver ISO image here and e1000 driver installer here using guest OS. After they are downloaded, shutdown your guest and start it with desired NIC. For example to start Windows XP guest in KVM with e1000 NIC use

kvm -localtime -m 2047 -soundhw all -boot d -cdrom /images/winxp.iso /guests/winxp.img -vga cirrus -cpu host -net nic,model=e1000 -net user

Install drivers for e1000 from installer downloaded before and restart windows guest. After that your windows guest should recognize e1000 NIC and show it is in 1G mode. Installation is almost the same for Virtio NIC just rename iso into zip and unpack it somewhere to install.

Hope this article will save some of your time :)

Thursday, July 29, 2010

Running RHEL 5 as a Guest Under Ubuntu 10.04 Lucid

I recently tried to run RHEL5 as guest under Ubuntu Linux 10.04 Lucid and my experiment ended with weird messages like shown below. It just popped up during running kvm and there were no way to fix it but start qemu without kvm. It helped but was so slow that almost unusable unless you have plenty of time to wait.
MP-BIOS bug: 8254 timer not connected to IO-APIC
After several attempts to fix it and get working RHEL5 for testing I found this post which has several options that works for test instance of RHEL5. It turned out simple kvm options like
-no-kvm-irqchip
-no-kvm-pit.    
can be used to make it boots like expected and it still works pretty fast versus -nokvm option.

Monday, April 13, 2009

Web Tools 3.0.4 Installation Through Update Site Fails With Error

I bumped in this problem several times and newer had time to find a way to fix it. Every time I try to install WTP I get this error Today I finally got through it :) The solution is described here and it is in removing and adding back update site which is used during installation. So did I. I added WTP Update Site and tired to install WTP Features from it. It failed. I removed WTP Update Site and added it back, then tried it again and it finally went without errors. Looks like it might depend on mirror selected for installation.