Community discussions

MikroTik App
 
rxfoote
newbie
Topic Author
Posts: 33
Joined: Thu Oct 04, 2012 12:21 am

Dual WAN/Failover

Tue Dec 16, 2014 11:59 pm

I have a RB1200, that I would like to setup for our two connections. The first as primary, and the 2nd as secondary. I would like it setup, so if the primary goes down, it automatically moves over to the 2nd, and then if the primary comes back up to automatically move back over. Any guidance in how to do this? Thanks!
 
User avatar
rmmccann
Member Candidate
Member Candidate
Posts: 182
Joined: Tue Sep 25, 2012 11:15 pm
Location: USA

Re: Dual WAN/Failover

Wed Dec 17, 2014 6:55 am

There are multiple ways, however I personally like this method best:
http://wiki.mikrotik.com/wiki/Advanced_ ... _Scripting

Just adjust your route distances accordingly to define primary/secondary WAN. I also recommend monitoring ISP DNS servers instead of default gateways as it will check connectivity beyond default gateway (if it can't ping the ISP DNS, it considers the route down and switches to the other connection).
 
jarda
Forum Guru
Forum Guru
Posts: 7756
Joined: Mon Oct 22, 2012 4:46 pm

Re: Dual WAN/Failover

Wed Dec 17, 2014 8:44 am

Better to monitor real public ip addresses accessibility then any server inside network of isp.
 
User avatar
rmmccann
Member Candidate
Member Candidate
Posts: 182
Joined: Tue Sep 25, 2012 11:15 pm
Location: USA

Re: Dual WAN/Failover

Wed Dec 17, 2014 4:19 pm

Better to monitor real public ip addresses accessibility then any server inside network of isp.
Debatable. I want something relatively close to that ISP's network connection and I don't trust that outside operators can't have outages just like an ISP.
 
jarda
Forum Guru
Forum Guru
Posts: 7756
Joined: Mon Oct 22, 2012 4:46 pm

Re: Dual WAN/Failover

Wed Dec 17, 2014 4:34 pm

Debatable? I do not think so.

Every approach can produce error. My approach can produce false "missing internet connection" and switch to backup link even it was not necessary. Your approach can produce false "online internet connection" and will not switch to backup line even the internet is not reachable. When my fault happen, I can see it after and search better checking destination ip, still having internet connection available. If your fault happen you are immediatelly out of the game without connection to internet.

Everytime you need to think on the purpose: To have failover backup. Are you able to run failover if you are not able to detect that connection to internet is broken?

Now try to debate.
Last edited by jarda on Thu Dec 18, 2014 11:52 am, edited 1 time in total.
 
User avatar
rmmccann
Member Candidate
Member Candidate
Posts: 182
Joined: Tue Sep 25, 2012 11:15 pm
Location: USA

Re: Dual WAN/Failover

Wed Dec 17, 2014 7:58 pm

No need to get snippy, bud. Just a difference of opinion. It's still debatable.

If you're using a single router with dual upstream and failover, you can use packet marks to maintain connection history/NAT tables, however if you operate
with multiple geographic locations (routers) and upstreams, you have no way to synchronize your connection history. A "fake" break results in temporary loss of service while it switches back to the other connection - having to re-establish connections (often with a different IP). Worse yet, if the connection to your remote peer is flapping, you also have a route that is flapping.

At least with "my preferred" method, if my uplink providers were to have a catastrophic routing failure (which would really be the only way they would be disconnected from the rest of the world), I can at least manually adjust the route and correct the issue. One thing I've learned is that "no internet" is often less frustrating than "broken internet".

Just because your method isn't the same as my method does not make one better or worse. There are many ways to skin a cat, my friend.
 
jarda
Forum Guru
Forum Guru
Posts: 7756
Joined: Mon Oct 22, 2012 4:46 pm

Re: Dual WAN/Failover

Wed Dec 17, 2014 9:18 pm

Well, I did not mean it so hard how it maybe looks now.

Anyway, if other things than backuping failed internet acces are more important for you, its not the same goal anymore. When I build failover for small networks or for individuals, it is always better for them to have at least some access to internet then no access. Even the connections are broken and it is necessary to open the connections again.

Sure there can be other concerns more important as you mentioned. But do these things apply to situation of rxfoote? He will decide what he selects. If he operates big ISP network (I guess not from the way how he asks) then he would think much precisely about the routing and wan selection than asking how to make easily failover.

Now the question is: Which of our two possible faults is rxfoote ready to tolerate? To stay connected to ISP which has not access to internet or rather to flap even it maybe was not needed?
 
User avatar
rmmccann
Member Candidate
Member Candidate
Posts: 182
Joined: Tue Sep 25, 2012 11:15 pm
Location: USA

Re: Dual WAN/Failover

Wed Dec 17, 2014 9:28 pm

Now the question is: Which of our two possible faults is rxfoote ready to tolerate? To stay connected to ISP which has not access to internet or rather to flap even it maybe was not needed?
We've at least given the OP some insight into the situation.

rxfoote - please let us know how it works out.