Join us now. It is free, and it takes less than 1 minute to register.
Register now
Subscribe to our daily newsletter. It is free, and it comes with many benefits.


+ Reply to Thread
Page 94 of 113 FirstFirst ... 4484909192939495969798104 ... LastLast
Results 1,396 to 1,410 of 1692

Thread: Splitting international and local traffic on a Linksys WRT54G

  1. #1396
    Super Grandmaster
    Join Date
    Jan 2005
    Posts
    6,278
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    @swazz99jhb.

    I have an uncapped IS account as conn 0, a Saix blended account as conn 1 and local only as conns 2 through 5. The purpose of the SAIX account is to take over as the default international account from 8am to 8pm weekdays. The way to do this is documented earlier in this thread. I'll repeat it here. It is a fairly simple solution:

    1) Add the following after "chmod +x /tmp/checklink" in the startup script:

    Code:
    echo "0">/tmp/def.rt
    echo "echo \"\$2\"> /tmp/def.rt
    route del default dev ppp\$1
    route add default dev ppp\$2"> /tmp/setdr
    chmod +x /tmp/setdr
    This creates a script setdr <from connection> <to connection> which sets the connection that will act as the default route.

    2) The firewall script runs after every reconnect, so to restore the desired changes, add this code to the firewall script after "/tmp/build.wall":

    Code:
    /tmp/setdr 0 `cat /tmp/def.rt`
    3) Either run /tmp/setdr directly from the GUI command box (for immediate effect if necessary) and/or schedule changes in the DD-WRT GUI cron box:

    Code:
    0 20 * * 1-5 root /tmp/setdr 1 0
    0 8 * * 1-5 root /tmp/setdr 0 1
    4) Set up your config: As an example, my config is as follows:

    conn 0 int <ip range of int news server>
    ... serv commands for int p2p etc...
    link $uncpass $uncpass

    conn 1 aux ...
    ... drop commands for ports you want to disallow over this connection...
    link $saixname $saixpass

    conn 2 loc <ip of local news server>
    link $locname $locpass

    conn 3 aux ...
    ... news command for additional server...
    link $locname $locpass

    etc

    6) If you set this up during the 8am to 8pm weekday period. Run "/tmp/setdr 0 1" in the DD-WRT command box once you are up and running.

    So any international p2p or news traffic is set up for the uncapped account on conn 0, even if this is throttled during weekdays. Local access is always through the local account (browsing or occasional daytime newserver downloads). On weekdays browsing and html/ftp downloads go out conn 1, but after hours and weekends the saix bandwidth is preserved and the uncapped account becomes the default route.

  2. #1397
    Super Grandmaster
    Join Date
    Jan 2005
    Posts
    6,278
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    @swazz99jhb.

    If I read your post (instead of assume) you don't actually want anything complicated. There are some problems with the news commands in your config: This is how it should look:

    conn 0 int
    link $intname $intpass

    conn 1 loc $werk
    ddns $ddsyst $dduser $ddpass $ddhost $ddchip $ddpage
    serv tcp 1235 $mypc
    serv udp 1235 $mypc
    serv tcp 1515 $mypc
    link $locname $locpass

    conn 2 aux
    serv tcp 1234 $mypc
    serv udp 1234 $mypc
    link $cybname $cybpass

    conn 3 aux $quake3 $saixnews
    link $auxname $auxpass

    conn 4 aux
    news $saixnews 331 $mypc
    link $auxname $auxpass

    conn 5 aux
    news $saixnews 332 $mypc
    link $auxname $auxpass

    conn 6 aux
    news $saixnews 333 $mypc
    link $auxname $auxpass

    Connections to IS news should simply default to local conn 1 on port 119.
    Connections to SAIX news will default to conn 3 on port 119.
    Your extra news servers look okay.

    Specifically you can't use

    news $isnews $mypc or
    news $saixnews $mypc

    without specifying a port number. The script will get confused!

    Is the WA account really an IS account? They haven't yet moved onto their own network?

  3. #1398
    Senior Member
    Join Date
    Nov 2005
    Location
    Johannesburg
    Posts
    213
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    GC you're a GOD!! The people ask and you provide :-)

    Script is working like a charm. Just got my 4mb line activated as well so I'm really in 7th Heaven!!

    08:00 - 01:00 Afrihost International (1GB - Auto TopUp 2GB)
    01:00 - 08:00 Cybersmart International (3 GB x 5 = 15 gig)
    24x7 - WebAfrica IS Local (30GB)
    24x7 - WebAfrica SAIX Local PrePaid (1 GB) - 4 Connections in script

    All running on WRT54GL.
    Last edited by swazz99jhb; 10-11-2009 at 05:15 PM.

  4. #1399
    Senior Member
    Join Date
    Apr 2008
    Location
    Port Elizabeth
    Posts
    435
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Excuse me here, but I'd just like to find something out.
    What exactly does the news command do? Does it allow you to connect to the news server multiple times through different ports?
    If that is so, is it possible to use it for other programs as well? For example, the free ventrilo server runs on 3784 and it cannot be changed. Is it possible to use the news command on the router to route the traffic through a port such as 3785 to the ventrilo server in your network listening on 3784?
    Not too sure if what I wrote is understandable, so is it possible to make an external port of 3785 route to an internal port of 3784?
    Thanks!

  5. #1400
    Super Grandmaster
    Join Date
    Jan 2005
    Posts
    6,278
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Quote Originally Posted by Jonno2343 View Post
    Excuse me here, but I'd just like to find something out.
    What exactly does the news command do? Does it allow you to connect to the news server multiple times through different ports?
    Yes, although the aim is to connect via a different ip address and thus increase the amount of connections you have to the server. Using different ports internally is what makes it possible.

    If that is so, is it possible to use it for other programs as well? For example, the free ventrilo server runs on 3784 and it cannot be changed. Is it possible to use the news command on the router to route the traffic through a port such as 3785 to the ventrilo server in your network listening on 3784?
    Not too sure if what I wrote is understandable, so is it possible to make an external port of 3785 route to an internal port of 3784?
    Thanks!
    The news command allows you to use different internal ports which get converted back to the standard 119 when requests leave your network. Then when the reply comes back on 119 via the same interface it went out on it is simply converted back to the internal port number you specified in the news command.

    In other words, the news command allows many internal ports to communicate over one external port. But the opposite, having one internal port and many external ports won't work at all. While you can convert the incoming Ventrilo traffic from port 3785 to 3784 as it arrives, the reply traffic coming from the Ventrilo server will always be on port 3784 with nothing at all to uniquely distinguish the source of the request. Replies will all go out via the default routes (either int or loc). Generally, when the incoming and outgoing interfaces don't match the client/server conversation will fail (error 404).
    Last edited by Gatecrasher; 10-11-2009 at 09:59 PM.

  6. #1401
    Senior Member
    Join Date
    Apr 2008
    Location
    Port Elizabeth
    Posts
    435
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Ok, I see.
    Thanks very much for that explanation! Clears things up for me
    Jonno

  7. #1402
    Super Grandmaster JetsetWilly's Avatar
    Join Date
    Jul 2008
    Posts
    25,257
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Default

    Gatecrasher - is it possible to do channel bonding with multiple concurrent connections to the same account on these routers?

    I was thinking about the R500 uncapped chilli thing where you get (e.g.) 2x 256k concurrent connections and channel bond them to form 1 512k connection. Is this a possibility? I imagine it may depend on how they throttle you - whether it's per NAS or per IP...

  8. #1403
    Grandmaster
    Join Date
    Apr 2008
    Location
    Cape Town
    Posts
    2,450
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Why? They have a 512k offering for R1000.

  9. #1404
    Super Grandmaster JetsetWilly's Avatar
    Join Date
    Jul 2008
    Posts
    25,257
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Default

    Quote Originally Posted by TheRift View Post
    Why? They have a 512k offering for R1000.
    Why when you can get 512k for R500

  10. #1405
    Senior Member dawbomb's Avatar
    Join Date
    Nov 2009
    Location
    Johannesburg
    Posts
    122
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hey all,

    I've written a script to split traffic between local only and international connections on a Telkom duoPlus 300WR router. Works like a charm

    I've also created a site to host such applications. Obviously my script is on there. If you've written a similar script for a different router, or a better script for the same one, please let me know! Contact details are on the site.

    So far the current script on there only runs from linux, but its not too difficult to convert to a Windows script, I just haven't had the time.

    If you're interested in using the script (free of course - I've made no attempt to hide the source code), check out http://sites.google.com/site/localrouter/.

  11. #1406
    Grandmaster
    Join Date
    Apr 2008
    Location
    Cape Town
    Posts
    2,450
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Can you hide the source code of a script?

    I'll find the link on the mikrotik wiki for doing the same thing on a routerboard and add it to your site.

  12. #1407
    Super Grandmaster JetsetWilly's Avatar
    Join Date
    Jul 2008
    Posts
    25,257
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Default

    Cool - I think it's a great idea to share this info...
    About hiding the source for a script - a script is just that - source and nothing more. It's not compiled code so no, you can't 'hide the source'.

  13. #1408
    Senior Member dawbomb's Avatar
    Join Date
    Nov 2009
    Location
    Johannesburg
    Posts
    122
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Quote Originally Posted by TheRift View Post
    Can you hide the source code of a script?
    Ok so maybe I didn't think that line through properly!

    Quote Originally Posted by TheRift View Post
    I'll find the link on the mikrotik wiki for doing the same thing on a routerboard and add it to your site.
    Shot
    The world would be better off if it were run by engineers.

  14. #1409
    Super Grandmaster
    Join Date
    Jan 2005
    Posts
    6,278
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    @dawbomb,

    You are quite welcome to link to this script here. Just make sure the information you give is accurate. This script also

    changes the routing tables on your ADSL router, enabling all computers on the network to have cheap local bandwidth, and browse international sites at the same time.
    But the statement

    If the type is "Script", Local Router comes as a program which needs to be run from a computer, usually whenever the router is restarted or if a connection is dropped. This is not ideal, but is better then nothing. Unfortunately different scripts need to be written for different operating systems.
    would not apply in this case.

    The linksys script is customized by the user and then saved to the router's nvram via the DD-WRT GUI. It does not need to be reloaded on a reboot or rerun when a connection is dropped. The only OS that matters is the one on the router. It will work on any router running under DD-WRT midi or standard firmware. You can check out compatible routers on dd-wrt.com

  15. #1410
    Super Grandmaster
    Join Date
    Jan 2005
    Posts
    6,278
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Quote Originally Posted by mbp View Post
    Gatecrasher - is it possible to do channel bonding with multiple concurrent connections to the same account on these routers?

    I was thinking about the R500 uncapped chilli thing where you get (e.g.) 2x 256k concurrent connections and channel bond them to form 1 512k connection. Is this a possibility? I imagine it may depend on how they throttle you - whether it's per NAS or per IP...
    All things are possible (nah, not really). The physical restraint is the maximum upload and download speed of your line. The next restraint is whether the ISP's servers treats your two connections as separate or not - I think it is highly likely that they would see them as separate. Finally, the restraint is how to bond the accounts?

    The script doesn't do load balancing, but I have seen solutions for doing just that on the dd-wrt site. I think if you look up DUAL WAN, there are some solutions that can be adapted to Multiple PPPoE.

    But even with the current script you could direct specific protocols, like p2p traffic over one connection while leaving the other connection as your default route for all your other web activities, or for using with other distinct protocols.

+ Reply to Thread
Page 94 of 113 FirstFirst ... 4484909192939495969798104 ... LastLast

Tags for this Thread

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •