Wednesday, December 24, 2014

EdgeMax Router slow to hand out DHCP address

When arriving home after working on another wireless network I noticed my laptop was quick to connect to wireless, but slow to get a proper IP address.  It was faster to issue an ipconfig /release and ipconfig /renew command then wait for an IP address.


I discovered that the EdgeMax router dhcp service is, by default. not running in Authortative mode.  Since it wasn't, here is what was happening.
  • Client connects and issues a DHCP request with a requested IP address (the last one I was using).
  • EdgeMax running in non-authortative mode ignores the request because it had a requested address that didn't match the address scope the EdgeMax is configured for.
  • Client requestes a number of times before it finally times out.
  • After timeout client issues a generic address request without an address
  • EdgeMax responds to request with an address
  • Client uses the address and is operational.

I issued this command...
set service dhcp-server shared-network-name DHCP-POOL-NAME authoritative enable 
Switching the EdgeMax DHCP service to authortative mode the timeout went away.  Here's what happens, and there is no timeout or delay involved.
  • Client connects and issues a DHCP request with a requested IP address (the last one I was using).
  • EdgeMax running in authortative mode denies the request.
  • Client issues a new request for an address from the server
  • EdgeMax responds to request with an address
  • Client uses the address and is operational.

Reference for Non-Authortative and Authortative differences.

2 comments:

  1. Nicholas PiaseckiMay 20, 2015 at 8:02 AM

    Thank you! Was scratching my head over this one. I love it when someone's taken the time to post a quirky issue and its resolution to their blog!

    ReplyDelete
  2. Thanks you Jeremy! I discovered this problem myself today and your post 100% confirms this problem. From now on I'll always do my DHCP config from CLI on EdgeRouter. This behavior is true for EdgeRouter Pro, EdgeRouter Lite and the new EdgeRouter X as far as I know.

    ReplyDelete