Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I recently upgraded to Fedora 11 and found out that VMware 1.0.5 doesn't seem to work as it did in Fedora 10.
I decided to give VirtualBox a try and have run into problems trying to get the bridged network feature to work.
I have created this file under: /etc/sysconfig/network-scripts/ifcfg-br0
I am able to get the br0 up and running and I have connection to the internet on the HOST machine. However when I run the VM in VirtualBox it is unable to obtain an IP from my DHCP server. I have changed the interface that the VM uses to the br0 but it still isn't able to get an address. I am wondering if there is a step that I am missing? I have pieced together all that I have done from various posts but still seem to be missing something. Can anyone help me shed some light on this problem?
You also need to set up "tap"s into the bridge for the VirtualBox VMs. I found a lot of ill-informed chat on the Internet about how to do this and eventually realised that VirtualBox's own documentation is the most accurate and almost complete.
Here's a commented /etc/interfaces file for two VirtualBox VMs. You'll have to translate from /etc/interfaces to /etc/sysconfig/network-scripts but the architecture should be the same.
Code:
# The loopback network interface
auto lo
iface lo inet loopback
# eth0 is the physical interface.
# Bridging software will configure eth0 when it is added as a port to br0 (below)
# This minimal configuration avoids message "Ignoring unknown interface eth0=eth0"
auto eth0
iface eth0 inet manual
up ifconfig $IFACE 0.0.0.0 up
down ifconfig $IFACE down
# tap0 is a tap into the brige below for use by VirtualBox.
# * Guest OS will configure, hence "manual"
# * VirtualBox will be running with owner c (and group vboxusers), hence user c
# * "ifconfig" is part of ifupdown package
# * "tunctl_user" is part of tunctl package
auto tap0
iface tap0 inet manual
up ifconfig $IFACE 0.0.0.0 up
down ifconfig $IFACE down
tunctl_user c
# tap1, same as tap0, for second VirtualBox VM
auto tap1
iface tap1 inet manual
up ifconfig $IFACE 0.0.0.0 up
down ifconfig $IFACE down
tunctl_user c
# br0 is a bridge connecting physical interface eth0 to OS, tap0 and tap1
# * Bridge port stanzas must appear earlier
# * Static configuration
# * No need for spanning tree protocol (stp) because no other bridges on network
auto br0
iface br0 inet static
address 192.168.1.47
network 192.168.1.0
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
bridge_ports eth0 tap0 tap1
bridge_maxwait 0
bridge_stp off
What version of VirtualBox are you running? I run Debian (haven't played with another distro for a while) and also Windows Vista and XP and Server 2003 and have run the 2.x series VirtualBox on all of them, you don't even need to set up bridged networking anymore, Set that information in the VM settings and select the appropriate adapter, no need to ad a br interface or tap interfaces, etc...
What version of VirtualBox are you running? I run Debian (haven't played with another distro for a while) and also Windows Vista and XP and Server 2003 and have run the 2.x series VirtualBox on all of them, you don't even need to set up bridged networking anymore, Set that information in the VM settings and select the appropriate adapter, no need to ad a br interface or tap interfaces, etc...
Thanks for the "heads up". I'm running VirtualBox 2.1.2, just about to change to 3.0.2. The bridging setup is untouched since installing 1.6.0.
As it says in the VirtualBox 3.0.0 User Manual, The way bridged networking works has been completely rewritten with VirtualBox 2.0 and 2.1, depending on the host operating system. From the user perspective, the main difference is that complex configuration is no longer necessary on any of the supported host operating systems. That makes things easier and boot a little quicker
It's ok, I make it complicated myself anyways, I run VBox on my laptop and have the VMs bridged to the wireless, but critical vms that I want netwworkign with all the time I bridge with a dummy adapter I set up on a seperate class C subnet. And I understand about the network hassles, back when I was playing with XEN it was a bear, I eventually had to set up dummy networkign for the xen machine and run the host with proxy software to get internet access, the only nice advantage to that was that regardless of whether the host was connected via wireless or wired I always had Internet if the host had Internet.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.