1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

24h pppoe disconnect?

Discussion in 'Tomato Firmware' started by blackbits, Jan 3, 2007.

  1. blackbits

    blackbits LI Guru Member

    Hello,

    i switched from DD-WRT to Tomato and really like it. Thanks for such an amazing firmware.

    But I'm missing an option to select the time when the router should reconnect the DSL connection.
    I tried ' cru a reconnect "00 04 * * * /tmp/ppp/ip-down" ' already, but it seems that there are problems with reconnecting. The web-interface says that the router is offline although there is normal internet access.

    Is there a better way to implement a 24h reconnect?

    Thanks in advance
    blackbits
     
  2. bogderpirat

    bogderpirat Network Guru Member

    hi,
    i have the same problem. i was using dd-wrt before and had a
    55 5 * * * root /usr/bin/killall pppoecd​
    in a cronfile, and now, on tomato, even a
    cru a dslreconnect "55 5 * * * killall pppoecd"​
    won't work. i have tried to killall pppoecd via ssh and that works just fine, don't quite know why it won't via cron. i keep my router in time-sync via ntp, so the problem shouldn't come from there.
     
  3. blackbits

    blackbits LI Guru Member

    'killall pppoecd' works for me even when using cru. But the router doesn't reconnect.

    Thanks
    blackbits
     
  4. The_Unknown

    The_Unknown Network Guru Member

    I use a reboot script as an alternative for pppoe reconnection.

    In your case blackbits, it would be:

    cru a reboot "00 4 * * * reboot"
     
  5. digitalgeek

    digitalgeek Network Guru Member

    Why do you need to cycle you pppoe connection? I run mine in keep alive and I had one problem in 5 years (ISP dennies it was their fault)
     
  6. F157

    F157 LI Guru Member

    the thing is that you don't want to have the disconnect while you're playing online at 8pm...

    after an update of the firmware i have to stay up till 3 or 4am and click disconnect and connect; this way the reconnects occurs at night... but i think it should be no big thing to integrate an option where i can set a time for a fast disconnect-connect...
     
  7. The_Unknown

    The_Unknown Network Guru Member

    In my case, if I start the pppoe connection between 1 AM and 8 AM, I get unlimited traffic (downloads) during the connection time, which is 17h55 duration per connection.
     
  8. bogderpirat

    bogderpirat Network Guru Member

    i for one try to set my isp-imposed daily disconnect to some hour in the night at which i'm in no way going to be doing something important, such as playing an online game, which would be interrupted by a disconnect and consequent redialing.

    the command in my earlier posting actually works now. it didn't before, but now it does. i suspect goblins.
     
  9. digitalgeek

    digitalgeek Network Guru Member

    Keep alive won't effect traffic, your ISP shouldn't drop the connection if there is traffic. If the connection is dormant your ISP will drop the session (just like with dial up) your router should detect this, reconnect you and update dyndns. I have been doing this since Thibor and never had any issues.
     
  10. bogderpirat

    bogderpirat Network Guru Member

    there is a mandatory disconnect almost all of the providers in my country have to adhere to if they sell connections to private customers. this occurs precisely 24 hours after the pppoe connection was first established. there is no way of circumventing that, you can only have it happen at a time at which it doesn't annoy you.
     
  11. F157

    F157 LI Guru Member

    exactly, so i hope there could be an option like in dd-wrt, where you select the time when the router disconnects and reconnects...
    or how do you make it "happen at a time at which it doesn't annoy you"?
     
  12. bogderpirat

    bogderpirat Network Guru Member

  13. Ldfa

    Ldfa LI Guru Member

    You can use also 'service wan stop' and 'service wan start' or better 'service wan restart'.
     
  14. der_Kief

    der_Kief Super Moderator Staff Member Member

    Hi,

    i added cru a PPPoE_Restart "00 5 * * * service wan restart" and this works like it should. But today i recognized that the manually added cron job was not there anymore after the upgrad to version 1.03 yesterday. Is it normal that manually added cron jobs are missed after an upgrade ? All other configuration is taken over.

    der_Kief
     
  15. digitalgeek

    digitalgeek Network Guru Member

    if it's not added to NVRAM it will not remain after a reboot, which does occur after an upgrade. Try adding it to your startup script
     
  16. der_Kief

    der_Kief Super Moderator Staff Member Member

    Thanks, i will try that. So i have to put cru a PPPoE_Restart "00 5 * * * service wan restart" in startup script ? But why stay the cron jobs that are created by "Access Restrictions" ?

    der_Kief
     
  17. bogderpirat

    bogderpirat Network Guru Member

    probably because access restrictions, as well as startup scripts are saved into nvram. putting the command into startup scripts worked fine for me.
     
  18. feynman

    feynman Network Guru Member

    Well I also have unlimited traffic if I connect between 1-8 AM.
    Here's the Init script I use in tomato:

    cru a reconnect1 "05 1 * * * /tmp/ppp/ip-down"
    cru a reconnect2 "55 7 * * * /tmp/ppp/ip-down"

    I also have the Connect Mode set to "Keep Alive"

    Hope this helps!
     
  19. der_Kief

    der_Kief Super Moderator Staff Member Member

    OK i put it in the init script and now it works perfect. But i had to reboot the router to test this ( its not good for my longest uptime :wink: )

    der_Kief
     
  20. F157

    F157 LI Guru Member

    Now it works for me, too.

    I'm lovin tomato :)
     
  21. Kibe

    Kibe LI Guru Member

    Does this option auto reconnect PPPoE at 5 a.m. local router time?

    cru a PPPoE_Restart "00 5 * * * service wan restart"

    If I change it to:

    cru a PPPoE_Restart "00 7 * * * service wan restart"

    Does it mean reconnection will occur at 7 a.m. local router time?
     
  22. der_Kief

    der_Kief Super Moderator Staff Member Member

    Yes thats correct.

    der_Kief
     

Share This Page