[U-Boot-Users] DHCP: u-boot vs. busybox

Udi Finkelstein u-boot-users at udif.com
Sun Aug 29 01:01:45 CEST 2004


Hi,

I ran into something similar lately. I don't remember the exact RFC 
terminology, but here it is:

When you send a DHCP request, there are 2 ways to specify your ID:
1. The MAC address field in the DHCP request.
2. A "client ID" tag in the DHCP option field.

After wasting a few hours with a cisco router to give me a specific IP 
address for each MAC address I had, I found out that:

1. Windows machines usually report their MAC address by prepending the 
ARP interface type (0x01 for Ethernet) to the MAC address and report 
this as the "Client ID".

2. U-boot simply uses the MAC address field.

Cisco routers have separate commands for specifying each type:

ip dhcp pool XXXX
    import all
    host 10.10.10.xxx 255.255.255.0
    client-identifier 0100.0c41.d584.3d
    client-name xxxxx

or:

ip dhcp pool XXXX
    import all
    host 10.10.10.xxx 255.255.255.0
    hardware-address 000c.41d5.843d
    client-name xxxxx

Hope this helps,
Udi

Steven Scholz wrote:

> Hi there,
> 
> I just noticed that my board get's different IPs from the DHCP server 
> depending on wether U-Boot or busybox udhcpc did the request.
> 
> The dhcp server log shows that they're using the same MAC:
> 
>  From U-Boot:
> DHCPDISCOVER from 00:a0:33:01:f9:97 via eth0
> DHCPOFFER on 10.0.10.220 to 00:a0:33:01:f9:97 via eth0
> DHCPREQUEST for 10.0.10.220 (10.0.2.9) from 00:a0:33:01:f9:97 via eth0
> DHCPACK on 10.0.10.220 to 00:a0:33:01:f9:97 via eth0
> 
>  From linux-2.4.27/busybox:
> DHCPDISCOVER from 00:a0:33:01:f9:97 via eth0
> DHCPOFFER on 10.0.10.174 to 00:a0:33:01:f9:97 via eth0
> DHCPREQUEST for 10.0.10.174 (10.0.2.9) from 00:a0:33:01:f9:97 via eth0
> DHCPACK on 10.0.10.174 to 00:a0:33:01:f9:97 via eth0
> 
> Doing several rebooting I still see the same.
> 
> Any idea how this could happen? I thought I would get the same IP fir 
> the same MAC as long as the lease is valid...
> 
> 





More information about the U-Boot mailing list