cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2491
Views
5
Helpful
2
Replies

DHCP manual bindings/reservations don't work when using hardware-address

TOBY SIMMONS
Level 1
Level 1

We have used manual bindings in a limited fashion and can assign them fine if we use the "client-identifier" as the matching criteria; The problem is we need to expand our usage of them but don't want to depend on the client machines having a properly filled in "dhcp client-id" field. The problem is we cannot get manual bindings to assign using simply the hardware-address / MAC address.

Here is the config we are using:

 

ip dhcp pool res_test
   host 10.2.17.80 255.255.255.0
   hardware-address 5c96.9d74.efa7
   default-router 10.2.17.1
   dns-server 10.2.17.14 10.2.17.113
   domain-name ardemgaz.com
   netbios-name-server 10.2.17.14 10.2.17.113

And here is what the DHCP table looks like:

show ip dhcp binding
10.2.17.80       5c96.9d74.efa7          Infinite                Manual
10.2.17.193      015c.969d.74ef.a7       Dec 04 2014 08:40 PM    Automatic

You see that the client got the address 10.2.17.193 but should have received 10.2.17.80; We have tried including the "Ethernet" prefix of 01 in the hardware-address using this config:

ip dhcp pool res_test
   host 10.2.17.80 255.255.255.0
   hardware-address 015c.969d.74ef.a7
   default-router 10.2.17.1
   dns-server 10.2.17.14 10.2.17.113
   domain-name ardemgaz.com
   netbios-name-server 10.2.17.14 10.2.17.113

But then you get the following, after clearing the binding and renewing the lease from the client:

show ip dhcp binding
10.2.17.80       015c.969d.74ef.a7          Infinite                Manual
10.2.17.193      015c.969d.74ef.a7       Dec 04 2014 08:50 PM    Automatic

Which makes no sense to me. Is it even possible to specify the MAC address to receive a manual binding? This is using the following version:

show ver
Cisco Internetwork Operating System Software
IOS (tm) MSFC Software (C6MSFC-JSV-M), Version 12.1(27b)E1, RELEASE SOFTWARE (fc2)
1 Accepted Solution

Accepted Solutions

ghostinthenet
Level 7
Level 7

The IOS DHCP server is going to use the client identifier if one is present and will only fall back on the MAC address if one isn't present. I've been working with these devices for years and still haven't found a way to create a universal reservation that will work for both client identifiers and MAC addresses. At this point, I usually fall back to a server-based DHCP solution that has this flexibility and configure a DHCP relay on the switch.

View solution in original post

2 Replies 2

ghostinthenet
Level 7
Level 7

The IOS DHCP server is going to use the client identifier if one is present and will only fall back on the MAC address if one isn't present. I've been working with these devices for years and still haven't found a way to create a universal reservation that will work for both client identifiers and MAC addresses. At this point, I usually fall back to a server-based DHCP solution that has this flexibility and configure a DHCP relay on the switch.

gary.mulhern
Level 1
Level 1

hardware-address is only used for BOOTP. For DHCP you'll need to use client-identifier. Some devices (like Cisco switches) will send a very long hex string for the client identifier but most devices (like a PC) will just send it's MAC address prepended with the media type 01.

 

Using your example you would need...

ip dhcp pool res_test
   host 10.2.17.80 255.255.255.0
   client-identifier 015c.969d.74ef.a7
   default-router 10.2.17.1
   dns-server 10.2.17.14 10.2.17.113
   domain-name ardemgaz.com
   netbios-name-server 10.2.17.14 10.2.17.113
Review Cisco Networking for a $25 gift card