Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

When I put data on a wire in qemu what sets the upper limit on the rate of data I can transmit? The situation is I set up two machines A and B

create two tap interfaces

openvpn --mktun --dev tap0 --user `id -un`
openvpn --mktun --dev tap1 --user `id -un`

bridge between them

/usr/sbin/brctl addbr br0
/usr/sbin/brctl addif br0 tap1
/usr/sbin/brctl addif br0 tap0

bring up the bridge

/sbin/ifconfig br0 10.0.0.1 netmask 255.255.255.0 broadcast 10.0.0.255

I start them with a tap device

qemu -m 256 -hda diskA.img -net nic -net tap,ifname=tap0,script=no
qemu -m 256 -hda diskB.img -net nic -net tap,ifname=tap1,script=no

The tap device writes data to a userspace, but where is that userspace ,what are its constraints and how do I control it?

share|improve this question
    
Why did you create the tap interface with openvpn? Openvpn is running in this moment? –  Sacx Feb 13 '13 at 12:04

1 Answer 1

up vote 0 down vote accepted

In your case the userspace application is qemu. TUN/TAP devices are kernel space virtual devices. To control tap interface use ifconfig, ip, brctl etc.

The upper limit of your transmitted data is dictated by your CPU. If you want to control the limit then you should use tcng (traffic control language interpreter).

Also, if you want just to connect the qemu's between them, you can use just 1 tap interface and share it between qemu's.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.