VirtualBox

Opened 8 years ago

Closed 7 years ago

#14615 closed defect (fixed)

Linux kernel can't get IP address over DHCP on Windows host => Fixed in SVN

Reported by: andyp1973 Owned by:
Component: network Version: VirtualBox 5.0.4
Keywords: PXE, DHCP, IP, Wireless Cc:
Guest type: Linux Host type: Windows

Description

A virtual machine is setup with a bridged Ethernet adapter (Intel Pro/1000 MT Desktop) and configured to remote boot using the PXE boot ROM.

On a Linux host (CentOS 6.7 running VirtualBox 4.3.31-101940 the boot process proceeds as follows: PXE Boot ROM gets IP address from DHCP server, runs the pxelinux.0 file to get the correct configuration file. Configuration file specifies the guest Linux kernel command line to include ip=dhcp along with a bunch of NFS root file system stuff. The Linux kernel boots, gets the same IP address allocated again and mounts the correct NFS file system.

On a Windows host (tried Windows 7 x64 with VirtualBox 4.3.31-101940 and Windows 10 x64 with versions up to and including 5.0.51-102781) the PXE boot ROM successfully gets an IP address from the DHCP server but the guest Linux kernel doesn't it just sits sending DHCP requests which never get responded to.

Looking at the network adapter on Windows using WireShark I can see the DHCP request coming from the MAC address of the guest followed immediately by a matching DHCP request from the host adapter to which it is bridged but never any responses.

Only key difference is that in the Linux host case the guest adapter is bridged to a wired interface on the host whereas on the Windows hosts it is bridged to a wireless interface.

Change History (12)

in reply to:  description comment:1 by Valery Ushakov, 8 years ago

Replying to andyp1973:

Only key difference is that in the Linux host case the guest adapter is bridged to a wired interface on the host whereas on the Windows hosts it is bridged to a wireless interface.

Right. "Bridging" to wireless is not really bridging. The guest shares the MAC of the host and the host does a sort of MAC-NAT translation based on IP addresses.

On a Windows host (tried Windows 7 x64 with VirtualBox 4.3.31-101940 and Windows 10 x64 with versions up to and including 5.0.51-102781) the PXE boot ROM successfully gets an IP address from the DHCP server but the guest Linux kernel doesn't it just sits sending DHCP requests which never get responded to.

Can you get a packet capture for the guest using VirtualBox builtin capture?

Can you also get a simultaneous packet capture at the DHCP server?

comment:2 by andyp1973, 8 years ago

The packet capture file from the VirtualBox built in capture was too large to add directly to the ticket but can be downloaded from https://www.dropbox.com/s/7mdqfx252vucbp3/kerneldhcpfail.7z?dl=0

I'll work on a packet capture at the DHCP server but as it is the same machine that is the internet gateway and firewall it will be very noisy unless we capturing only DHCP related packets will be enough.

Andy.

in reply to:  2 comment:3 by Valery Ushakov, 8 years ago

Replying to andyp1973:

I'll work on a packet capture at the DHCP server but as it is the same machine that is the internet gateway and firewall it will be very noisy unless we capturing only DHCP related packets will be enough.

Yes, DHCP and ARP should be enough.

comment:4 by andyp1973, 8 years ago

There is a new file available at https://www.dropbox.com/s/bcijaixab6t3wbz/dhcplogs.7z?dl=0 which contains a guest PCAP file and a corresponding PCAP file from the DHCP server which captures ARP and DHCP requests (UDP ports 67 and 68).

Andy.

comment:5 by Valery Ushakov, 8 years ago

Thanks. I think I see what the problem is. When bridging to wireless we rewrite DHCP packets to always request broadcast replies and update the UDP checksum accordingly, but the code doesn't check if UDP checksumming is disabled (checksum set to zero), so the rewritten DHCP DISCOVER packet that we send to the router ends up with bad checksum. I'll try to provide a test build for you to test later today.

comment:6 by Valery Ushakov, 8 years ago

I've uploaded a Windows test build, revision 102800. Please, give it a try.

comment:7 by andyp1973, 8 years ago

I can confirm that test build 102800 resolves this issue.

Thank you for your quick response in looking into this and providing a fix.

Andy.

comment:8 by Valery Ushakov, 8 years ago

Summary: Linux kernel can't get IP address over DHCP on Windows hostLinux kernel can't get IP address over DHCP on Windows host => Fixed in SVN

The fix will be in the next 5.0.* and 4.3.* releases.

comment:9 by Frank Mehnert, 8 years ago

Fixed in VBox 5.0.6.

comment:10 by Frank Mehnert, 8 years ago

Resolution: fixed
Status: newclosed

comment:11 by rpr-nospam, 7 years ago

Resolution: fixed
Status: closedreopened

I am seeing the same issue on VirtualBox 5.1.8 running on MS Windows 10 Pro. 64-bit.

I created a guest with the network bridged to the host's wired NIC and installed Debian 8.6 32-bit. When Debian boots it cannot get an IP address from local DHCP server running on MS Windows Server 2012 R2.

The same guest system created on the Ubuntu 16.04 64-bit host is getting an IP address from the same DHCP server.

comment:12 by Valery Ushakov, 7 years ago

Resolution: fixed
Status: reopenedclosed

This bug is about bridging to wireless, which is quite different from bridging to wired. Please, file a new bug. Please provide packet captures too.

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use