[reopened] Bridged interface doesn't work properly
[reopened] Bridged interface doesn't work properly
I have two physical hosts running VirtualBox- one OS X and one Linux. I have a direct network connection between the two hosts (en1 on the Mac, eth1 on the Linux box).
I cannot ping from a VM hosted on the OS X side to the Linux side. When the same host was a Linux box, it worked just fine, so it's some sort of OS X issue.
OS X machine has IP address 172.16.0.1 on interface en1
Linux machine has IP address 172.16.0.2 on interface eth0
The VM on the OS X machine has IP address 172.16.0.13. I can successfully ping 172.16.0.1 from within the VM, but I cannot ping 172.16.0.2.
I do see some network traffic on the Linux side when running tcpdump but not everything goes through.
Is there a misconfiguration? How can I effectively troubleshoot this further?
I cannot ping from a VM hosted on the OS X side to the Linux side. When the same host was a Linux box, it worked just fine, so it's some sort of OS X issue.
OS X machine has IP address 172.16.0.1 on interface en1
Linux machine has IP address 172.16.0.2 on interface eth0
The VM on the OS X machine has IP address 172.16.0.13. I can successfully ping 172.16.0.1 from within the VM, but I cannot ping 172.16.0.2.
I do see some network traffic on the Linux side when running tcpdump but not everything goes through.
Is there a misconfiguration? How can I effectively troubleshoot this further?
Last edited by EmmEff on 20. Sep 2011, 22:29, edited 2 times in total.
Re: Bridged interface doesn't work properly
Nobody experiencing the same?
I even upgraded to VB 4.0.0 r69151 with hopes that the problem would be resolved.
It just seems that the traffic is bridged onto the interface locally, but not outside of the VirtualBox host machine. Is this an OS X setting perhaps? Firewalls are definitely disabled between the hosts.
I even upgraded to VB 4.0.0 r69151 with hopes that the problem would be resolved.
It just seems that the traffic is bridged onto the interface locally, but not outside of the VirtualBox host machine. Is this an OS X setting perhaps? Firewalls are definitely disabled between the hosts.
-
jdcynical
- Posts: 1
- Joined: 14. Jan 2011, 11:16
- Primary OS: Mac OS X other
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Win 7
Re: Bridged interface doesn't work properly
No, you are not the only one having issues with bridged interfaces.
I recently had to rebuild my machine (filesystem error), and ever since then, I'm unable to make use of bridged interfaces.
In my case, the windows 7 guest I have locks up. The opensolaris guest would respond at first, then disappear off the network.
Switching the guests to NAT seems to work. I've tried versions 3.2.12 r68302 and 4.0.0 r69151 with the same results.
This is on Mac OS 10.6.6 running in 64bit mode, with the e1000 desktop adaptor for the guests. Needless to say, it's very annoying.
EDIT: It seems to be working now. After I dug through the forums a bit more, I found one person who was having bridging issues as well. The fix they used, and what seems to work for me as well, was to switch from the e1000 to the amdnet II card. Personally, I would have figured that the e1000 would have been the best choice, but this seems to work correctly. Might be worth a shot in your case.
I recently had to rebuild my machine (filesystem error), and ever since then, I'm unable to make use of bridged interfaces.
In my case, the windows 7 guest I have locks up. The opensolaris guest would respond at first, then disappear off the network.
Switching the guests to NAT seems to work. I've tried versions 3.2.12 r68302 and 4.0.0 r69151 with the same results.
This is on Mac OS 10.6.6 running in 64bit mode, with the e1000 desktop adaptor for the guests. Needless to say, it's very annoying.
EDIT: It seems to be working now. After I dug through the forums a bit more, I found one person who was having bridging issues as well. The fix they used, and what seems to work for me as well, was to switch from the e1000 to the amdnet II card. Personally, I would have figured that the e1000 would have been the best choice, but this seems to work correctly. Might be worth a shot in your case.
Re: Bridged interface doesn't work properly
I will try switching interfaces in the guest, but this appears to be a bug in the OS X version of VirtualBox. Between two Linux boxes running VirtualBox, this functions perfectly.
Thanks for the info.
Edit: changed the interface in the OEL 5.5 guest to AMD using the pcnet32 driver; everything functions the same as with the Intel adapter before- local connectivity only. Cannot access physical systems on the same network
Thanks for the info.
Edit: changed the interface in the OEL 5.5 guest to AMD using the pcnet32 driver; everything functions the same as with the Intel adapter before- local connectivity only. Cannot access physical systems on the same network
Re: Bridged interface doesn't work properly
Problem still seems to exist with 4.0.4.
Is nobody using OS X in this configuration or is my setup broken?
Is nobody using OS X in this configuration or is my setup broken?
Re: Bridged interface doesn't work properly
Answering my own question... I needed to enable IP forwarding to make this work.
From a shell prompt:
sudo sysctl -w net.inet.ip.forwarding=1 net.inet.ip.fastforwarding=1
I guess nobody has done this before. I run an pretty extensive configuration, which includes software to automatically provision VMs so I might be one of the more advanced VirtualBox on OS X users.
From a shell prompt:
sudo sysctl -w net.inet.ip.forwarding=1 net.inet.ip.fastforwarding=1
I guess nobody has done this before. I run an pretty extensive configuration, which includes software to automatically provision VMs so I might be one of the more advanced VirtualBox on OS X users.
-
BillG
- Volunteer
- Posts: 5106
- Joined: 19. Sep 2009, 04:44
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows 10,7 and earlier
- Location: Sydney, Australia
Re: [resolved] Bridged interface doesn't work properly
That doesn't make any sense to me. IP forwarding is certainly turned off by default in many OS versions, but turning it on or off should have no effect on what you were doing. IP forwarding is only required if you need to forward traffic from one IP subnet to another.
If all of the IP addresses are in the same IP subnet I cannot think of how IP forwarding could be involved. Which machine did you enable IP forwarding on?
If all of the IP addresses are in the same IP subnet I cannot think of how IP forwarding could be involved. Which machine did you enable IP forwarding on?
Bill
Re: [resolved] Bridged interface doesn't work properly
I thought IP forwarding was for forwarding network traffic between different network interfaces on the same physical host?BillG wrote:That doesn't make any sense to me. IP forwarding is certainly turned off by default in many OS versions, but turning it on or off should have no effect on what you were doing. IP forwarding is only required if you need to forward traffic from one IP subnet to another.
I remember always having to enable it when using my Linux server as an Internet gateway/NAT box.
I enabled it on the OS X host running VirtualBox.If all of the IP addresses are in the same IP subnet I cannot think of how IP forwarding could be involved. Which machine did you enable IP forwarding on?
-
BillG
- Volunteer
- Posts: 5106
- Joined: 19. Sep 2009, 04:44
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows 10,7 and earlier
- Location: Sydney, Australia
Re: [resolved] Bridged interface doesn't work properly
Indeed that is what it does. That is why you need it enabled when you use the machine as a router. But as far as I can see, your machines are all in the same IP subnet and the same network. If you are using bridged mode you are not routing. They are completely different things.EmmEff wrote:BillG wrote: I thought IP forwarding was for forwarding network traffic between different network interfaces on the same physical host?
I remember always having to enable it when using my Linux server as an Internet gateway/NAT box.
If it works for you with IP forwarding enabled, that is fine. I just can't think of any reason why it makes any difference.
Bill
Re: [resolved] Bridged interface doesn't work properly
Yes, you're right, it doesn't make sense. The only thing I can think of is that VirtualBox is routing the traffic from the VM (which is supposed to be bridged to en1) to en0 and then en0 is forwarding the traffic to en1. Without IP forwarding enabled, the traffic is being stopped dead on the en0 interface.
I can't help but think this is a bug, but nobody else seems to be having the same issue.
I can't help but think this is a bug, but nobody else seems to be having the same issue.
-
muraiki
- Posts: 5
- Joined: 13. May 2011, 15:58
- Primary OS: Mac OS X Leopard
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Win7
Re: [resolved] Bridged interface doesn't work properly
I have a Mac Pro with a similar problem in that I can't see the domain or even connect to anything on the network/internet with bridged networking on a Windows 7 VM. NAT works ok.
I found some other threads and the one thing in common is that we are all running Windows 7 VMs, like jdcynical said in this thread. Are you using Win7 or are you running something else in your VM?
I tried the above two fixes but neither worked, so I'm not 100% certain if this problem is related to my problem. But I'm curious as to what VMs you are running.
I found some other threads and the one thing in common is that we are all running Windows 7 VMs, like jdcynical said in this thread. Are you using Win7 or are you running something else in your VM?
I tried the above two fixes but neither worked, so I'm not 100% certain if this problem is related to my problem. But I'm curious as to what VMs you are running.
Re: [resolved] Bridged interface doesn't work properly
I am primarily running Linux in my VMs (Ubuntu and CentOS/Oracle Enterprise Linux), but I had the same issue with Windows 7.
Re: [resolved] Bridged interface doesn't work properly
It appears that some form of this bug is back with 4.1.2r73507.
I cannot connect to a host connected to the network to which the bridged interface is connected BUT this host is able to receive a DHCP response, so it's partially working.
I do have IP forwarding enabled on the OS X host running VirtualBox (as described above) to no avail.
Unfortunately, I have to drop VirtualBox for the time being because I need this to work
I cannot connect to a host connected to the network to which the bridged interface is connected BUT this host is able to receive a DHCP response, so it's partially working.
I do have IP forwarding enabled on the OS X host running VirtualBox (as described above) to no avail.
Unfortunately, I have to drop VirtualBox for the time being because I need this to work
-
ost99
- Posts: 1
- Joined: 25. Sep 2011, 23:59
- Primary OS: MS Windows 7
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Debian, Windows
Re: [reopened] Bridged interface doesn't work properly
If you also have a host-only or internal interface, make sure it is configured without gateway on the guest side.
Windows: If you're using Eset smart security, you need to make changes to the firewall settings (NAT works, bridge doesn't work or stops working after a few minutes).
If your guest if debian-based, make sure you have the correct mac in the persistent net settings (in /etc/udev/rules.d/). Or just remove the persistent-net file and modify the *-persistent-net-generator.rules (in /lib/udev/rules.d/) to ignore virtualbox interfaces. (Common problem after cloning a guest or after manually refreshing mac).
Windows: If you're using Eset smart security, you need to make changes to the firewall settings (NAT works, bridge doesn't work or stops working after a few minutes).
If your guest if debian-based, make sure you have the correct mac in the persistent net settings (in /etc/udev/rules.d/). Or just remove the persistent-net file and modify the *-persistent-net-generator.rules (in /lib/udev/rules.d/) to ignore virtualbox interfaces. (Common problem after cloning a guest or after manually refreshing mac).
Re: [reopened] Bridged interface doesn't work properly
It's funny how Centos - which is open source - runs natively on VirtualBox with a bridge - you just create an ifcfg-br0 file
DEVICE=br0
TYPE=Bridge
BOOTPROTO=dhcp
ONBOOT=yes
and then point the ifcfg-eth0 to this bridge. brctl is present in a minimal install.
With Oracle Enterprise Linux 5 4 you have to NAT to VBox, which is OK I, but you can't ssh to it. Doesn't Oracle make OEL? Doesn't Oracle make VirtualBox? Seems like they would have figured this out by now.
DEVICE=br0
TYPE=Bridge
BOOTPROTO=dhcp
ONBOOT=yes
and then point the ifcfg-eth0 to this bridge. brctl is present in a minimal install.
With Oracle Enterprise Linux 5 4 you have to NAT to VBox, which is OK I, but you can't ssh to it. Doesn't Oracle make OEL? Doesn't Oracle make VirtualBox? Seems like they would have figured this out by now.