DHCP Lease Renewal

Discussion in 'HyperWRT Firmware' started by prowler1968, Feb 14, 2006.

  1. prowler1968

    prowler1968 Network Guru Member

    Last night, working on my laptop on a wireless connection to WRT54GSv4 with Thibor 13, I clicked on a link in a web page that I was logged in to. Right at the same time I clicked SUBMIT, my SystemTray icon for my wireless adapter popped up a message which said "You are now connected...".

    A) I was already connected
    B) The web page came back with a connection error that the site could not be found
    C) When I checked the network connection properties, I found that my DHCP lease renewed at the same time as the connection error that I had on that web page.

    I think that the network interface (at least the wireless portion) was reset when the DHCP lease was renewed. Can anyone else confirm that this has happend? Either the connection was lost and a DHCP lease renewal was forced for some reason, or a previous lease expired and reset the wireless interface, causing a temporary loss of connectivity (just a couple of seconds) My router is set up for WEP security.
  2. bcat

    bcat Network Guru Member

    I don't know much about the inner workings of DHCP, but I think the client is supposed to attempt a renewal before the lease expires to prevent a loss of connectivity. My guess is that your wireless connection just dropped out temporarly.
  3. RSL_Fan

    RSL_Fan Network Guru Member

    Same symptoms???

    I believe this has happened to me and it affects both wired and wireless. I haven't verified it, but will look into it the next time it happens and post results.

    Seems to happen every day to day and a half. I believe my ISP renews the lease about every 18 hrs. Connectivity to the internet will be lost for a couple minutes and then i'll be able to reconnect. I'm still able to access the router's configuration pages...just no internet access. I haven't noticed any loss of connection with the router on the wireless PC. Maybe my symptoms are different than yours.

    Maybe it's an issue with my ISP.

    WRT54GS v.2
    Thibor 13d (most recent version)
  4. prowler1968

    prowler1968 Network Guru Member


    My lease renewal was not between the router and the modem from my ISP, but from my client PC and the router.

    I don't recall if I was on the computer the previous day (I would have a 1 day lease, which would have expired during the period I was on the computer last night). If I had not been on the computer within the last 24 hours, I would have gotten a lease for a 24 hour period (by firmware default, I may change that), which should not have expired during my usage last night.

    I'll check my computer log to see if I was logged on approx. 24 hours before this event took place and would have caused a renewal.
  5. myersw

    myersw Network Guru Member

    I also have a wrt54gs v4 with thibor 13d installed. I am not experiencing any loss of connection on either the wired or wireless network during lease renewal. If the DHCP client on the PC plus thibor 13d are working correctly, you should not experience any outage.
    DHCP does a lease renewal at the half way point in the lease time. In other words, if the lease is set to one day then the client will request a lease renewal at 12 hours. If you want to test this you can set the lease time to say 10 minutes. The renewal then will happen at 5 minutes after you have forced a lease renewal by doing (on a windows PC) ipconfig /release then ipconfig /renew. Will then have a 10 minute lease and you can see if there is a network connection issue by looking in the event viewer to see if there are errors.
  6. prowler1968

    prowler1968 Network Guru Member

    I'll check that out with the lease renewal period. Since I was working on the wirless connection, I could have lost my connection with the router (not likely, I have a signal strength that fluctuates between Good and Excellent, mostly Excellent). Even so, that should not have caused a lease renewal, just a temporary loss of connectivity, which would have been indicated with the message I received "You are now connected..." popping up from the system tray wireless network icon.
  7. NateHoy

    NateHoy Network Guru Member

    Keep in mind that normally a client will attempt to renew a DHCP lease at 50% elapsed time, then again at 75% elapsed time.

    Whether the client can maintain a stable connection should be up to the client, not the DHCP server. So if a client:

    1. ...disconnects unexpectedly, the reconnect would normally involve a renewal of the DHCP lease as part of the connection.

    2. ... does a normal 50% time elapsed lease renewal, the client SHOULD cache the old DHCP result until the new lease is taken out, but this may or may not be the case based on client implementation.

    So the symptom for a poorly coded client will be the same. Loss of DHCP then a renewal of the lease period.

    You can force a disconnect by briefly turning off and on your wireless access point (on a HyperWRT Tofu or Thibor box with the SecureEasySetup turned off, just push the CISCO logo to turn off the radio, then push it again to turn the radio on).

    Keep in mind that if you have intermittent interference (a neighbor with a cordless phone that does a security retrain every 18 hours on an alternate channel that happens to stomp on yours, or any other periodic use of the 2.4 Ghz unlicensed band), you can very well get excellent connections and still lose them from time to time.

    You can test for bad lease renewal code by setting a low lease period and seeing if the problem happens frequently. If it does, check for new drivers for your client. I sincerely doubt that Thibor would reset the entire WiFi connection for a single DHCP lease renewal, though I suppose it is possible...
  8. NateHoy

    NateHoy Network Guru Member

    Update: Just switched my laptop to wireless, WPA/TKIP using Tofu 13c (same wireless code as Thibor, if I understand it correctly). Lease period set to 30 minutes. 7 IM clients (2 over VPN), 2 Lotus Notes, 3 telnet connections. I'll know for sure in 15 minutes if DHCP lease renewal causes problems, because FOR SURE one of my connections will complain...
  9. prowler1968

    prowler1968 Network Guru Member

    Thanks - Look forward to your findings.

    I am using a Linksys WPC54G wireless pc card. The newest drivers are from 2004, which is what I am using, so no help trying to update drivers.

    I used to be on the DD-WRT firmware, but there were issues similar to this when the lease renewal would occur, the wireless/wired interfaces would get reset. If Linksys is using the same Broadcom drivers integrated in their firmware, maybe it could be an issue there.

    Either way, the issue has not caused me a big problem. I was on the internet and also had Remote Desktop accessing my office computer. The Remote Desktop flashed a disconnect icon and then almost instantly reconnected (Remote Desktop was minimized in the background while I was on that administration site (I pressed refresh and got back to the page where I needed to be). Like I said, not a huge problem, not to say I couldn't see a more disruptive problem occur in the future.
  10. NateHoy

    NateHoy Network Guru Member

    After at least two hours, I can happily report that my lease has renewed a number of times, and the renewal has been completely and utterly invisible on my network. My laptop connections are as solid as wired connections. No drops, no hesitations, no problems whatsoever.

    My Vonage router did at least two lease renewals while I was in the middle of a long conference call and I had ZERO problems with that.


    - Router: WRT54G V4 running HyperWRT Tofu 13c, transmit power set to 25%.
    - Laptop: Dell Latitude D600 with built-in wireless, located about 6 feet from router, signal strength at -39db, running Funk Odyssey as the client driver, WPA/TKIP encryption.

    My environment is in a basement of a house with aluminum siding, in rural Maine with the nearest house about 200 yards away through trees, and he doesn't have a computer. Needless to say, the only possible sources of interference are my 2 2.4Ghz phones that have never been problem children, and my microwave. ;)

    I *did* have a connection drop when I applied the settings to update the lease renewal. But I expect something on the order of 5-10 seconds of outage whenever I apply ANY settings to the router. That's normal.

    But DHCP lease renewal has never been a problem for me, wired OR wireless. Setting it from my old 24 hours to the new 30 minutes has just caused them to happen more often, but I've never experienced a glitch that wasn't explainable by other means.

    I'd take a hard look at interference sources, or check your clients for the latest drivers that might fix DHCP renewal issues. I honestly don't think your router is your problem.
  11. prowler1968

    prowler1968 Network Guru Member

    Nate -
    Thanks for your reply with your test results. I live in a rural area of NC and have no wireless networks in my neighborhood, so no issue there. NO 2.4GHZ cordless phones (not in my home at least), microwave was not running.

    Since I have the most recent driver (not that new, 04), I doubt that I'll be seeing one anytime soon.

    The only source of interference that I could have is a 2.4GHZ wireless video monitor (receiver) with a transmitter upstairs in my son's bedroom. It runs 24/7 and doesn't seem to cause an issue. I have 2 TIVO units with Linksys wireless network adapters. Since they are B devices, I run my network in B Only mode, even though my notebook adapter is a G device. I read that would sometimes be slower throughput in mixed mode. Could have just been fluke. Unless I see more issues, I'll pretty much just ignore what happened.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice