PDA

View Full Version : can I choose a different network adapter in kvm/qemu


gstt
April 3rd, 2008, 03:39 PM
I installed kvm/qemu successfully in my ubuntu Fiesty. The default network adapter is Realtek RTL8028 with 10M speed. Can I choose another network adapter with 100M or higher speed?

I tried the cmd :
kvm -net nic,model=?

But this only showed the general help message.

msisamonopoly
April 5th, 2008, 08:12 AM
try model=pcnet

gstt
April 7th, 2008, 11:38 AM
try model=pcnet

Thank you. This gives me a new adapter: AMD PCNET Family PCI Ehternet Adapter. It comes with 100M duplex mode.

However, after I chose "100Mbps full Duplex" from "External PHY", I still got 10M bps speed in the network connection dialog box. Restarting machine did not change anything.

Here is the full command I start kvm:

sudo kvm -no-acpi -m 512 -cdrom /dev/cdrom -net nic,model=pcnet -net tap mykvm.img

I went through the help message and tried to google qemu documents but still could not find how to set the network link speed to 100Mbps.

problematique
April 8th, 2008, 02:26 AM
I'm having the same issue but with a different network adapter. I suppose 10M will have to do.

jserink
July 19th, 2008, 01:46 AM
Here is my startkvm100.sh script:
kvm -boot c -hda /home/jserink/winxp1.img -m 384 -net nic,vlan=0,model=rtl8139 -net user -localtime &
/home/jserink/qgt-2005-03-02-19/host-linux 127.0.0.1 > /dev/null 2>&1 &

Everything you need to know is in there. I'm getting ~25Mbps throughput which is much better than the 2-4Mbps you get with the 10M NIC.

Looking for a 1000MNIc support to clean this up even further if anyone has suggestions.

Cheers,
John

Milan Knizek
January 4th, 2009, 02:26 PM
I tried the cmd :
kvm -net nic,model=?

But this only showed the general help message.

You need to supply also the image name (also named "target" in the man page):
kvm -net nic,model=\? ubuntu.img