Previous month:
August 2015
Next month:
March 2016

DD-WRT WAN DHCP client disconnect

At some point, it seems that Comcast/Xfinity may have changed how they handle DHCP leases. I have had this issue starting in the past week or so: at some point, my WAN connection goes down, and multiple reboots of both the router and the cable modem do not restore the connection. However, turning the power off and then back on does seem to work.

After having only my Mac directly on the cable modem for a few days, which meant that it was the only device (except for phones) which was on the internet, it got really annoying not being able to watch Netflix and Hulu.

One more set of cold reboots, and I noticed that the DHCP lease time remaining was less than an hour. I have a vague notion it was more like 24 hours, before, but I could easily be mistaken. Anyway, I discovered this post on the DD-WRT forums. Apparently, some ISPs push the DHCP lease renewal, which the router's firewall blocks. So, the fix is to add an iptables rule to accept the renewal:

iptables -I INPUT -p udp --dport 68 -j ACCEPT

In the router web interface, go to Administration -> Commands. In the Commands text box, type in the line above, and click Save Firewall. That runs the command and saves it to the iptables config to persist across boots.