DHCP between Peplink and WAN modem

Request: Allow parameters to be passed to udhcpc when the router tries to acquire an IP address from the modem.

Charter Communications (and possibly other companies) handles DHCP requests from the router in an “interesting” way. :mad:

When the DHCP lease runs out, very often (4 - 5 times a week) the router cannot get an IP address from the cable modem. The “fix” is to unplug the router, power down the modem, remove the coax and then reboot it, or to connect the PC with the correct MAC address, which gets an IP instantly.

If you do a web search for “Charter DHCP issue” there is a lot of information about it.

I have copied and pasted the following from this site. Although the author is talking about the Tomato router, I think it describes the issue, as well as a realistic fix:

<snip>

Details:
The root cause of the problem is that Charter’s DHCP server stops communicating with any DHCP client that attempts 5 communications in a 3 minute window. Once blacklisted, devices are not able to communicate with the DHCP server until there has been 3 minutes of inactivity. However, Tomato’s default behavior is to try 5 communications per attempt, and to try more frequently than every 3 minutes to connect.

When making the connection, some cable modems appear to establish the upstream connection before the downstream is fully established. This allows packets to travel FROM the router but not back TO the router. When the Tomato router attempts to get its IP address, the packets TO the DHCP server are received, but the responses are not. This causes Tomato to retry over and over, getting itself blacklisted. Once blacklisted, Tomato attempts often enough to stay blacklisted.

When power is applied simultaneously (power comes back) to the cablemodem and router, certain cable modems startup at the same time as the Tomato router. This means that Tomato has a timing condition where (after a power outage), it gets itself blacklisted and will not obtain internet access without manual intervention. However, other cable modem models appear to startup much more quickly (or establish upload/download at the same time), and are not affected by the issue.

From a Charter Rep:
The amount of time that it takes to reestablish a connection makes me think we could have a DHCP denial issue. This is where something from the customer’s end is requesting an IP address from our DHCP servers more than 5 times in 3 minutes. The culprit of these issues is a router about 95% of the time. When this happens, your service is temporarily blocked. To fix it, the server has to be clear of all requests for 3 minutes. We usually accomplish this by unplugging modem and router for that time.

Fix:
The fix is to reconfigure udhcpc to try fewer times and to wait longer between attempts. This prevents the router from being blacklisted. This is achieved by passing “–retries=2 –timeout=5 –tryagain=310″ to udhcpc.

Workaround:
The issue can be worked around by unplugging the Tomato router for 5 minutes, and then plugging it back in. Alternatively, you can power on the cable modem fully before starting the router.

Reproduced this issue on a WRT54GL with the following cablemodems:
Motorola SB 5100
Ambit U10C018.80

Issue did not exist with a WRT54GL the following cablemodems:
Cisco DPC3010

</snip>

Thank you for your considering this.

You mentioned “or to connect the PC with the correct MAC address, which gets an IP instantly.”

Does this mean they have your PC’s MAC address whitelisted? If so, why not do a MAC clone on that WAN interface and change the MAC so it is the same as your PC.

Might be worth a try…

I do have the PC’s MAC address cloned on the router. Without it cloned, I can’t connect at all.

As for why the PC works, I *think *it is because Windows sets the DHCP Broadcast flag by default, but most linux based routers do not…

The following snippet is from this site

<snip>
Looking at Ethereal dumps, it appears that my Linksys box does not set the DHCP broadcast bit. Neither does dhcpcd in its default mode (this can be changed by doing “dhcpcd -B eth0”, at which time it works fine with linux). Windows’s default mode is to set the DHCP broadcast bit. Unfortunately, it looks like the Linksys box does not have an option to set that bit.

But, you may ask (more likely, you’ve stopped reading by this poing :), why is the linksys box able to get an IP address after the Windows box (or Linux with the -B option set in dhcpcd) gets and IP address first? Well, the “tunnel” is already up; the modem is now receiving unicast packets. The linksys box sends a DHCP Request, requesting a unicast reply. And Charter’s DHCP server sends a unicast reply. And all is good.

</snip>

Again, allowing dhcpcd / udhpcd parameters to be set on the Peplink just might fix the Charter DHCP problem…

>> ** Request: Allow parameters to be passed to udhcpc when the router tries to acquire an IP address from the modem.**

Any possibility that this could be considered? … allowing custom parameters might assist in many situations… Thanks

Just trying to keep this request alive, one way or another…

I would understand “No way will we consider this…” - I wouldn’t be happy, but it would be acceptable. I could find another solution, maybe putting the Balance 20 behind my TomatoUSB router and cable modem (or build my own linux box and sell my Balance 20)

Again, the request is: **to allow parameters to be passed to udhcpc when the Balance 20 connects to the cable modem **

This is a feature of TomatoUSB as well as DD-WRT.

Thank you for your consideration…

Thanks for the feature request. This is definitely a Charter issue and I’m surprised that they do it this way, I would think this generates a lot of unneeded support calls they have to deal with. My cable modems (not Charter) at my house have had the same “dynamic” public IP address for over 9 months now.

I can’t even think of a workaround off the top of my head. Maybe they can give you a different cable modem or a complimentary static IP? Anyways, we will take a look at if we can support this in a future firmware release.

Thank you for the response, I really appreciate it.

Yes, this is certainly a Charter issue. They will not give a different cable modem or a complimentary static IP address, ugh…

I know that this was added to TomatoUSB/DD-WRT because of this (and similiar) issues. I appreciate your looking into this!

Hi, It may be a charter issue, but if my Peplink balance 20 does not work with charter (the only cable co here in Western Colorado) do I return the Balance 20 and find another router that works with charter???

This has happened now 2 times in 13 days. I have to dis-connect the peplink for a few hours, before it can connect to the internet again. So my wifi hotspot is down for hours. Or, do I load another router in front of the peplink to talk to charter? (I tried waiting 3 minutes, then 5 minutes then 30 minutes and finally 2 hours minimum.)

I would call Charter and request the Cisco modem, the issue should then be resolved.