PPPoE dynamic IP - conditional WAN reconnect

Discussion in 'Tomato Firmware' started by tommyv, May 7, 2019.

  1. tommyv

    tommyv Addicted to LI Member

    I'm on PPPoE DSL, renewing a dynamic IP every 24h on WAN. My ISP has some IP ranges that cause speed drops. I noted those ranges.

    Is it possible to configure WAN to reconnect until on desired IP range and exclude unwanted IP range ?

    Thanks in advance
     
  2. eibgrad

    eibgrad Network Guru Member

    I don't know of anything that will do this automatically. You'll probably have to script it in the WAN up script.
     
  3. tommyv

    tommyv Addicted to LI Member

    Thanks, found a script on this forum that did it:

    Code:
    if [ "$(ifconfig ppp0 | grep "inet addr:XXX")" ]
      then 
        logger "Unwanted IP" `nvram get wan_ipaddr` "received on ppp0, restarting WAN."
        service wan restart
      else
        logger "Wanted IP" `nvram get wan_ipaddr` "received on ppp0."
    fi
     
    Last edited: May 7, 2019
  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