VirtualBox

Ticket #601 (closed defect: fixed)

Opened 7 years ago

Last modified 4 years ago

br0 not resolving: dhclient: No DHCPOFFERS received

Reported by: ToddAndMargo Owned by:
Priority: major Component: network
Version: VirtualBox 1.4.0 Keywords: No DHCPOFFERS received
Cc: Guest type: other
Host type: other

Description

I am trying to set up a "host interface" network between my

XP guest and my Linux host. "br0" does not resolve with my DHCP server: "No DHCPOFFERS received"

Guest=XP Pro, SP2 Host=CentOS5

# uname -r 2.6.18-8.1.8.el5

I have two nic: eth0 is the internal netwrok; eth1 connects to a DSL modem.

I also have a fully functioning DHCP server on eth0 (works perfectly with Parallels for Linux).

Following the directions for Fedora Core in the users manual do not work (or I am doing them wrong):

1) # chmod 0666 /dev/net/tun

2) /etc/sysconfig/network-scripts/ifcfg-br0: DEVICE=br0 TYPE=Bridge BOOTPROTO=dhcp ONBOOT=yes

3) /etc/sysconfig/network-scripts/ifcfg-eth0 DEVICE=eth0 TYPE=Ethernet BOOTPROTO=static BROADCAST=192.168.255.255 IPADDR=192.168.255.10 NETMASK=255.255.255.0 NETWORK=192.168.255.0 GATEWAY=192.168.255.10 IPV6ADDR= IPV6PREFIX= ONBOOT=yes USERCTL=yes IPV6INIT=no PEERDNS=no BRIDGE=br0

4)# sudo /sbin/service network restart br0 failed: FAILED, unable to resolve IP address. From my /var/log/messages:

dhcpd: DHCPOFFER on 192.168.255.198 to 00:30:48:78:8e:92 via eth0 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 7 DHCPDISCOVER from 00:30:48:78:8e:92 via eth0 dhcpd: DHCPOFFER on 192.168.255.198 to 00:30:48:78:8e:92 via eth0 dhclient: No DHCPOFFERS received.

5) #sudo VBoxAddIF vbox0 todd br0 Note: also tried it with user=root (did a VBoxDeleteIF first): no symptom change

6) In VirtualBox settings, set "network adaptors" to "Host Interface" and set “Interface name” to “vbox0”

7) started VB and got the same fail DHCP offcer as in step 4. VB refused to start.

This is this is my full messages log when I restart networking (note the message at the end):

#/etc/rc.d/init.d/network restart

Aug 31 21:14:40 rn1 avahi-daemon[3207]: Withdrawing address record for fe80::230:48ff:fe78:8e92 on br0. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Leaving mDNS multicast group on interface br0.IPv6 with address fe80::230:48ff:fe78:8e92. Aug 31 21:14:40 rn1 avahi-daemon[3207]: iface.c: interface_mdns_mcast_join() called but no local address available. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Interface br0.IPv6 no longer relevant for mDNS. Aug 31 21:14:40 rn1 kernel: br0: port 1(eth0) entering disabled state Aug 31 21:14:40 rn1 kernel: br0: port 2(vbox0) entering disabled state Aug 31 21:14:40 rn1 avahi-daemon[3207]: Interface eth0.IPv6 no longer relevant for mDNS. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Leaving mDNS multicast group on interface eth0.IPv6 with address fe80::230:48ff:fe78:8e92. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Interface eth0.IPv4 no longer relevant for mDNS. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Leaving mDNS multicast group on interface eth0.IPv4 with address 192.168.255.10. Aug 31 21:14:40 rn1 dhcpd: receive_packet failed on eth0: Network is down Aug 31 21:14:40 rn1 avahi-daemon[3207]: Withdrawing address record for fe80::230:48ff:fe78:8e92 on eth0. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Withdrawing address record for 192.168.255.10 on eth0. Aug 31 21:14:40 rn1 kernel: device eth0 left promiscuous mode Aug 31 21:14:40 rn1 kernel: br0: port 1(eth0) entering disabled state Aug 31 21:14:40 rn1 avahi-daemon[3207]: Withdrawing address record for 192.168.1.47 on eth1. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Leaving mDNS multicast group on interface eth1.IPv4 with address 192.168.1.47. Aug 31 21:14:40 rn1 avahi-daemon[3207]: iface.c: interface_mdns_mcast_join() called but no local address available. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Interface eth1.IPv4 no longer relevant for mDNS. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Withdrawing address record for fe80::230:48ff:fe78:8e93 on eth1. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Leaving mDNS multicast group on interface eth1.IPv6 with address fe80::230:48ff:fe78:8e93. Aug 31 21:14:40 rn1 avahi-daemon[3207]: iface.c: interface_mdns_mcast_join() called but no local address available. Aug 31 21:14:40 rn1 avahi-daemon[3207]: Interface eth1.IPv6 no longer relevant for mDNS. Aug 31 21:14:40 rn1 dhcpd: receive_packet failed on eth1: Network is down Aug 31 21:14:41 rn1 kernel: ADDRCONF(NETDEV_UP): eth0: link is not ready Aug 31 21:14:41 rn1 kernel: device eth0 entered promiscuous mode Aug 31 21:14:41 rn1 kernel: ADDRCONF(NETDEV_UP): eth1: link is not ready Aug 31 21:14:42 rn1 kernel: e1000: eth1: e1000_watchdog_task: NIC Link is Up 100 Mbps Full Duplex Aug 31 21:14:42 rn1 kernel: e1000: eth1: e1000_watchdog_task: 10/100 speed: disabling TSO Aug 31 21:14:42 rn1 kernel: ADDRCONF(NETDEV_CHANGE): eth1: link becomes ready Aug 31 21:14:42 rn1 kernel: e1000: eth0: e1000_watchdog_task: NIC Link is Up 100 Mbps Full Duplex Aug 31 21:14:42 rn1 kernel: e1000: eth0: e1000_watchdog_task: 10/100 speed: disabling TSO Aug 31 21:14:42 rn1 dhclient: DHCPREQUEST on eth1 to 255.255.255.255 port 67 Aug 31 21:14:42 rn1 dhcpd: DHCPREQUEST for 192.168.1.47 from 00:30:48:78:8e:93 via eth1: unknown lease 192.168.1.47. Aug 31 21:14:42 rn1 dhclient: DHCPACK from 192.168.1.1 Aug 31 21:14:42 rn1 avahi-daemon[3207]: New relevant interface eth1.IPv4 for mDNS. Aug 31 21:14:42 rn1 avahi-daemon[3207]: Joining mDNS multicast group on interface eth1.IPv4 with address 192.168.1.47. Aug 31 21:14:42 rn1 kernel: dsl-out Everything Else IN= OUT=eth1 SRC=192.168.1.47 DST=224.0.0.22 LEN=40 TOS=0x00 PREC=0xC0 TTL=1 ID=0 DF PROTO=2 Aug 31 21:14:42 rn1 avahi-daemon[3207]: Registering new address record for 192.168.1.47 on eth1. Aug 31 21:14:42 rn1 avahi-daemon[3207]: Withdrawing address record for 192.168.1.47 on eth1. Aug 31 21:14:42 rn1 avahi-daemon[3207]: Leaving mDNS multicast group on interface eth1.IPv4 with address 192.168.1.47. Aug 31 21:14:42 rn1 kernel: dsl-out Everything Else IN= OUT=eth1 SRC=192.168.1.47 DST=224.0.0.22 LEN=40 TOS=0x00 PREC=0xC0 TTL=1 ID=0 DF PROTO=2 Aug 31 21:14:42 rn1 avahi-daemon[3207]: iface.c: interface_mdns_mcast_join() called but no local address available. Aug 31 21:14:42 rn1 avahi-daemon[3207]: Interface eth1.IPv4 no longer relevant for mDNS. Aug 31 21:14:42 rn1 avahi-daemon[3207]: New relevant interface eth1.IPv4 for mDNS. Aug 31 21:14:42 rn1 avahi-daemon[3207]: Joining mDNS multicast group on interface eth1.IPv4 with address 192.168.1.47. Aug 31 21:14:42 rn1 kernel: dsl-out Everything Else IN= OUT=eth1 SRC=192.168.1.47 DST=224.0.0.22 LEN=40 TOS=0x00 PREC=0xC0 TTL=1 ID=0 DF PROTO=2 Aug 31 21:14:42 rn1 avahi-daemon[3207]: Registering new address record for 192.168.1.47 on eth1. Aug 31 21:14:42 rn1 dhclient: bound to 192.168.1.47 -- renewal in 38661 seconds. Aug 31 21:14:42 rn1 kernel: br0: port 1(eth0) entering learning state Aug 31 21:14:42 rn1 kernel: br0: port 2(vbox0) entering learning state Aug 31 21:14:43 rn1 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 4 Aug 31 21:14:43 rn1 kernel: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready Aug 31 21:14:44 rn1 avahi-daemon[3207]: New relevant interface eth1.IPv6 for mDNS. Aug 31 21:14:44 rn1 avahi-daemon[3207]: Joining mDNS multicast group on interface eth1.IPv6 with address fe80::230:48ff:fe78:8e93. Aug 31 21:14:44 rn1 avahi-daemon[3207]: Registering new address record for fe80::230:48ff:fe78:8e93 on eth1. Aug 31 21:14:44 rn1 avahi-daemon[3207]: New relevant interface br0.IPv6 for mDNS. Aug 31 21:14:44 rn1 avahi-daemon[3207]: Joining mDNS multicast group on interface br0.IPv6 with address fe80::230:48ff:fe78:8e92. Aug 31 21:14:44 rn1 avahi-daemon[3207]: Registering new address record for fe80::230:48ff:fe78:8e92 on br0. Aug 31 21:14:45 rn1 avahi-daemon[3207]: New relevant interface eth0.IPv6 for mDNS. Aug 31 21:14:45 rn1 avahi-daemon[3207]: Joining mDNS multicast group on interface eth0.IPv6 with address fe80::230:48ff:fe78:8e92. Aug 31 21:14:45 rn1 avahi-daemon[3207]: Registering new address record for fe80::230:48ff:fe78:8e92 on eth0. Aug 31 21:14:47 rn1 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 8 Aug 31 21:14:50 rn1 kernel: dsl-out Everything Else IN= OUT=eth1 SRC=192.168.1.47 DST=224.0.0.22 LEN=40 TOS=0x00 PREC=0xC0 TTL=1 ID=0 DF PROTO=2 Aug 31 21:14:55 rn1 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 14 Aug 31 21:14:57 rn1 kernel: br0: topology change detected, propagating Aug 31 21:14:57 rn1 kernel: br0: port 1(eth0) entering forwarding state Aug 31 21:14:57 rn1 kernel: br0: topology change detected, propagating Aug 31 21:14:57 rn1 kernel: br0: port 2(vbox0) entering forwarding state Aug 31 21:15:09 rn1 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 15 Aug 31 21:15:09 rn1 dhcpd: DHCPDISCOVER from 00:30:48:78:8e:92 via eth0 Aug 31 21:15:10 rn1 dhcpd: DHCPOFFER on 192.168.255.198 to 00:30:48:78:8e:92 via eth0 Aug 31 21:15:24 rn1 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 8 Aug 31 21:15:24 rn1 dhcpd: DHCPDISCOVER from 00:30:48:78:8e:92 via eth0 Aug 31 21:15:24 rn1 dhcpd: DHCPOFFER on 192.168.255.198 to 00:30:48:78:8e:92 via eth0 Aug 31 21:15:32 rn1 dhclient: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 12 Aug 31 21:15:32 rn1 dhcpd: DHCPDISCOVER from 00:30:48:78:8e:92 via eth0 Aug 31 21:15:32 rn1 dhcpd: DHCPOFFER on 192.168.255.198 to 00:30:48:78:8e:92 via eth0 Aug 31 21:15:44 rn1 dhclient: No DHCPOFFERS received.

Change History

comment:1 Changed 7 years ago by sandervl73

  • Status changed from new to closed
  • Resolution set to invalid

This looks to me like a configuration problem. If the bridge functions properly, then you will get a DHCP lease. You should ask such questions on our forum. Please reserve the bug tracker for genuine bugs.

comment:2 Changed 6 years ago by ToddAndMargo

  • Status changed from closed to reopened
  • Resolution invalid deleted

"Please reserve the bug tracker for genuine bugs."

The problem is not getting a bridge to work. The problem is the CRAPPY DOCUMENTATION. Please add it to your list of things to fix.

comment:3 Changed 6 years ago by Technologov

Try to read: (basic network bridge setup)  http://forgeftp.novell.com/lfl/.html/virtualbox.html Chapter: "Intermediate Topic: Networking via Host Bridging"

and this: (setup of advanced configuration, routing via guest + multi-bridging + DHCP + PPPoE)  http://forums.virtualbox.org/viewtopic.php?t=2278&start=15

Yes, the official documentation is a bit weak on this topic.

-Technologov

comment:4 Changed 6 years ago by ToddAndMargo

I do believe I FINALLY have it figured out. I wrote myself the following how to. Please feel free to clean it up and use it in your documentation. THIS BUG IS A DOCUMENTATION BUG. Host Networking works fine BUT WHO CAN FIGURE IT OUT BY READING THE DOCUMENTATION!

The only problem I have left is that the Guest XP can not browse the Host's Samba server by SMB name (IP works fine)

-T

~

T's CentOS 5 -- Virtual Box "Host Networking" bridge setup:

Note: a lot of this is taken from (with lots of refinements):

 http://www.linuxweblog.com/virtualbox-host-networking

iptables: after creating br0 at etho's expense, you have to

change all references to "eth0" in your firewall to "br0"

br0: will become the internal interface and have a "Fixed" (static)

IP address of 192.168.255.10

Support software (required);

"VBoxAddIF" from Virtual Basic

bridge-utils:

yum install bridge-utils  ftp://ftp.pbone.net/mirror/ftp.centos.org/5.0/os/i386/CentOS/bridge-utils-1.1-2.i386.rpm

/etc/rc.d/rc.local ~

# Set permissions on /dev/net/tun such that Virtual Box can use it /bin/chmod 0666 /dev/net/tun /bin/chmod 777 /dev/vboxdrv

# Restart the firewall /etc/{iamnottellingyou}

~ /etc/sysconfig/network-scripts/ifcfg-eth0 ~

DEVICE=eth0 TYPE=Ethernet ONBOOT=yes USERCTL=yes IPV6INIT=no PEERDNS=no BRIDGE=br0 ONBOOT=yes PROMISC=yes

~ /etc/sysconfig/network-scripts/ifcfg-br0 ~

DEVICE=br0 TYPE=Bridge BOOTPROTO=static BROADCAST=192.168.255.255 IPADDR=192.168.255.10 NETMASK=255.255.255.0 NETWORK=192.168.255.0 GATEWAY=192.168.255.10 ONBOOT=yes USERCTL=yes IPV6INIT=no PEERDNS=no PROMISC=yes

~ /etc/sysconfig/network-scripts/ifcfg-br0 ~

IPADDR=0.0.0.0 PROMISC=yes

Initial and permanent setup ~

#! /bin/bash

# load the tun module modprobe tunvi chmod 666 /dev/net/tun

# Create a new bridge and add the interfaces to the bridge. brctl addbr br0 brctl addif br0 eth0 /usr/bin/VBoxDeleteIF vbox0 /usr/bin/VBoxAddIF vbox0 tony br0 brctl addif br0 vbox0

# Bring up eth0 and vbox0 in promiscuous mode # Commended out as it should be handles in "network-scripts" #ifconfig eth0 promisc #ifconfig vbox0 0.0.0.0 promisc

brctl addif br0 vbox0

# Now reboot (restarting networking doesn't work) echo "Now reboot. (I have no idea why)"

comment:5 Changed 6 years ago by ToddAndMargo

Ooops:

/etc/sysconfig/network-scripts/ifcfg-br0 IPADDR=0.0.0.0 PROMISC=yes

Should be /etc/sysconfig/network-scripts/ifcfg-vbox0 IPADDR=0.0.0.0 PROMISC=yes

comment:6 Changed 6 years ago by frank

  • Component changed from other to network

comment:7 Changed 4 years ago by Technologov

br0 no longer exists in VBox lingo. This is since VBox 2.1, and it's new Host Networking mode.

Please close this bug.

Besides it is 2 (!!) years old.

-Technologov

comment:8 Changed 4 years ago by sandervl73

  • Status changed from reopened to closed
  • Resolution set to fixed
Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use