Fixing Slow Fedora PXE installations under KVM


I have been doing a lot of work with KVM, and bumped into an odd issue when PXE booting a Fedora 10 KVM guest. The installer (anaconda) would progress to the point where it would try to locate and configure the network interface, but would spit out the following error and wait for operator input:

+--------+ Network Error +---------+
| |
| There was an error configuring |
| your network interface. |
| |
| +-------+ |
| | Retry | |
| +-------+ |
| |
| |
+----------------------------------+

After doing a bit of profiling, I noticed that the guest was having issues initializing the Realtek interface (this is the default interface type presented to KVM guests by QEMU). To see if a different interface type cured my problems, I changed the NIC model to an e1000 by adding the “model” tag to the KVM guest XML file:

<interface type='bridge'>
<mac address='54:52:00:53:20:02'/>
<source bridge='br0'/>
<target dev='vnet2'/>
<model type='e1000'/>
</interface>

Once I made this simple change, the PXE install worked flawlessly. This was a fun problem to debug, and I learned a TON about QEMU, Anaconda, libvirt and several Linux profiling tools in the process. Viva la problem resolution!

This article was posted by Matty on 2009-06-09 21:11:00 -0400 -0400