> > If you are running a DHCP client, then when your dynamic ipaddr > changes your ping will continue to succeed and you won't be able to > tell that anything has changed. The better answer is to take control > of the software running on the gateway and just have a script *there* > watch for a ipaddr change. OpenWrt FTW!
In reality the assigned DHCP ip address on a DSL modem shouldn't change that often. In fact most providers will tie a the MAC Address of the DSL modem to a specific ip address in the DHCP pool via a mac address reservation for better record keeping. The only circumstances that the assigned DHCP ip address might change is if the there's a loss of ip connectivity between the DSL modem and the DHCP server that originally assigned the leased ip address and if there's an ip network reconfiguration / reassignment at the ISP. If you disconnect the DSL modem from the network and the reconnect it as long as it talks to the same DHCP server the originally assigned DHCP ip address should be reallocated according to how the DHCP life cycle works. If the assigned DHCP ip address does change, the ping should fail because the originally assigned DHCP ip address will be pulled back into the pool and very likely not reassigned within a few minutes. DLS modems are not requesting new IP addresses at the rate you would expect laptops connecting to a WIFI AP at an airport. If I were doing this, I'd spend a bit of time studying how often and under what circumstances the DHCP assigned ip address of your DSL modem changes before writing one line of code... > _______________________________________________ PLUG mailing list [email protected] http://lists.pdxlinux.org/mailman/listinfo/plug
