VirtualBox

Ticket #4552 (new defect)

Opened 5 years ago

Last modified 5 years ago

Virtual machine fails to start with bridged networking if there is one already running

Reported by: gutzmann Owned by:
Priority: major Component: network
Version: VirtualBox 3.0.2 Keywords:
Cc: Guest type: Linux
Host type: Linux

Description

I have a bridged setup with 3 identical machines utilizing bridged networking, linux software bridges and tap interfaces. The first machine just starts fine but the second one fails to start every time. This was not a problem with 2.2.4.

The error message says:

Failed to start the virtual machine Testbed-aFirstTest-vb1. Failed to open/create the internal network 'HostInterfaceNetworking-vb1_ch0' (VERR_INTNET_INCOMPATIBLE_TRUNK). Unknown error creating VM (VERR_INTNET_INCOMPATIBLE_TRUNK).

Tap interfaces are named vb0_ch0, vb1_ch0 and vb2_0.

Attachments

Testbed-aFirstTest-vb1-2009-07-16-20-36-59.log Download (29.3 KB) - added by gutzmann 5 years ago.
Testbed-aFirstTest-vb0-2009-07-20-16-41-41.log Download (30.0 KB) - added by gutzmann 5 years ago.

Change History

Changed 5 years ago by gutzmann

comment:1 in reply to: ↑ description Changed 5 years ago by gutzmann

Replying to gutzmann:

This was not a problem with 2.2.4.

I removed 3.0.2 to give 2.2.4 a try again. 2.2.4 fails with this very error message, too!

I recently upgraded from lenny/stable to squeeze/testing.

I would love to provide any information which could help resolving this issue. Going back to lenny/stable is unfortunately no option for me.

comment:2 in reply to: ↑ description ; follow-up: ↓ 3 Changed 5 years ago by gutzmann

Tap interfaces are named vb0_ch0, vb1_ch0 and vb2_0.

VirtualBox even fails to start when only one machine is involved which is configured to use two of the tap interfaces. Same error message. (tested with 2.2.4 only)

Changed 5 years ago by gutzmann

comment:3 in reply to: ↑ 2 ; follow-up: ↓ 4 Changed 5 years ago by gutzmann

Replying to gutzmann:

Tap interfaces are named vb0_ch0, vb1_ch0 and vb2_0.

VirtualBox even fails to start when only one machine is involved which is configured to use two of the tap interfaces. Same error message. (tested with 2.2.4 only)

The Testbed-aFirstTest-vb0-2009-07-20-16-41-41.log log file is the result of trying to start a virtual machine with three tap-interfaces (bridged networking) attached to it. Prior to the failed start I executed the following commands in order to setup the tap interfaces, add them to a bridge and force the bridge to form a chain-of-3 network topology:

echo Starting tap-interfaces ...
sudo tunctl -t vb0_ch0 -u dvd
sudo tunctl -t vb1_ch0 -u dvd
sudo tunctl -t vb2_ch0 -u dvd
sudo ifconfig vb0_ch0 0.0.0.0 promisc up
sudo ifconfig vb1_ch0 0.0.0.0 promisc up
sudo ifconfig vb2_ch0 0.0.0.0 promisc up
echo Starting bridge ...
sudo brctl addbr ch0
sudo ifconfig ch0 10.0.0.100 netmask 255.255.255.0 broadcast 10.0.0.255 up
echo Adding interfaces to bridge
sudo brctl addif ch0 vb0_ch0
sudo brctl addif ch0 vb1_ch0
sudo brctl addif ch0 vb2_ch0
echo Starting visibility procedures ...
echo Setting default policy of ebtables FORWARD chain to DROP and flushing it ...
sudo ebtables -P FORWARD DROP
sudo ebtables -F FORWARD
echo Ensuring visibility between the vboxes ...
sudo ebtables -A FORWARD -i vb0_ch0 -o vb1_ch0 -j ACCEPT
sudo ebtables -A FORWARD -i vb1_ch0 -o vb0_ch0 -j ACCEPT
sudo ebtables -A FORWARD -i vb1_ch0 -o vb2_ch0 -j ACCEPT
sudo ebtables -A FORWARD -i vb2_ch0 -o vb1_ch0 -j ACCEPT

Right now, I don't have any clue what the problem *could* be.

comment:4 in reply to: ↑ 3 Changed 5 years ago by gutzmann

Replying to gutzmann:

Replying to gutzmann: Right now, I don't have any clue what the problem *could* be.

Ok, I finally figured it out. The problem was with the interface names I used.

More specific: There has to be a bug in virtualbox preventing me from choosing perfectly fine names (as far as the linux kernel is concerned) for the tap interfaces. The only restrictions linux places on the interface names is length <= 15 characters, so vb0_ch0, vb1_ch0, cb2_ch0 should be perfectly fine as interface names. If I rename the tap interfaces to tap0, tap1, tap2 everything works like a charm.

Maybe a solution could be incorporated somehow into future virtualbox releases.

Cheers,

David

comment:5 Changed 5 years ago by frank

Interesting. I can't find such restriction in the code. AFAICS, the maximum size of a network interface is 63 characters...

comment:6 Changed 5 years ago by frank

Connecting from two different VMs to a TAP device with vb0_ch0 works just fine here on a Linux host. You didn't try to start a VM with different users, did you?

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use