Community discussions

MikroTik App
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

how to make failover with bonding?

Wed Aug 01, 2007 3:29 pm

I have 2 Router that connected with 2 local link. I want to make failover procedure using bonding methode on mikrotik Router B.
My Question is :
How to make this design working with using bonding methode. No routing.
Secondary Link (wireless) used if Primary Link fail and back to Primary Link if Primary Link available.

Router A have ip 192.168.0.1/30 (as gateway router)
Router B have ip 192.168.0.2/30 (Mikrotik)

My topologi is
bonding01.jpg
.

I'm sorry for my bad explanation. :oops: :oops:

regards
-newbe-
You do not have the required permissions to view the files attached to this post.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Wed Aug 01, 2007 3:39 pm

Could you give information about connection between RouterA (I assume MikroTik) and Switch.
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 7056
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: how to make failover with bonding?

Wed Aug 01, 2007 4:37 pm

RouterB side is very simple, because each line is connected to separate inerfaces.
But routers B case is more complicated. I think there is two options:
1) Create one tunnel through primary link from routerA to routerB, and another one through secondary link. After that you can set bonding on tunnel interfaces.
2) Other option is to connect one of links to different VLAN group and set bonding on VLAN interfaces. But it is possible that this method won't work correctly.
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 8:32 am

Could you give information about connection between RouterA (I assume MikroTik) and Switch.
Router A is Cisco Router with 1 fastethernet that connected to catalyst cisco manageable switch. Router A To Router B have 2 local link which have same vlan id in catalyst (id=10). I'm not exactly known about Cisco configuration (Router A), because I don't have any access. But, information about topologi as describe in picture.
Last edited by jagowan on Thu Aug 02, 2007 8:42 am, edited 1 time in total.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 8:36 am

I think routing is goint to be more easy configuration scenario to accomplish, as router A is Cisco.
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 8:45 am

I think routing is goint to be more easy configuration scenario to accomplish, as router A is Cisco.
Admin of Router A just give me instruction about unplug and plug the ethernet connector from 2 my local link to their catalist port that have same vlan group.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 8:51 am

The problem for the bonding, that you cannot achieve it with one router (one device), another device(s) should be used too.
You may setup routing load-balancing on the MikroTik RouterB for LAN network, that will load-balance data from the network over these two links.
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 8:59 am

we just want to use secondary link (wireless) in emergency only, not for balanced trafic, this day i have configure my Mikrotik Router B with bonding and fail over link can working properly, but.... i can't see the fix delay for switching from primary to secondary link, this is about 1sec until 40sec. I don't know my configuration is correct or not.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 9:07 am

How do you use bonding (together with the switch) ?
very easy configuration is the following,
main gateway to Ether2 and check-gateway=ping,
secondary gateway to Ether1 address and distance=2.
If I'm not mistaken switching should occur after 5/6 unsuccessfull pings (as main gateway will be disabled then).
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 9:10 am

How do you use bonding (together with the switch) ?
very easy configuration is the following,
main gateway to Ether2 and check-gateway=ping,
secondary gateway to Ether1 address and distance=2.
If I'm not mistaken switching should occur after 5/6 unsuccessfull pings (as main gateway will be disabled then).
how to describe "main gateway and secondary gateway" if we just have 1 gateway ip (192.168.0.1/30) in 2 local link.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 9:13 am

I doubt that you have this subnet for both Ether1 and Ether2 interface.
I was thinking about Ether1 as main gateway for RouterB and Ether2 as secondary one.
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 10:04 am

Hmm, bonding can't used for this scenario ?
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 12:25 pm

What is your second device for the bonding ?
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 12:38 pm

What is your second device for the bonding ?
[admin@MikroTik] > /interface bonding print
Flags: X - disabled, R - running
0 R name="bonding1" mtu=1500 mac-address=00:04:AC:36:4B:5B arp=enabled
slaves=ether1-intel,ether2-onboard mode=balance-xor primary=none
link-monitoring=mii-type2 arp-interval=100ms mii-interval=20ms
down-delay=0s up-delay=0s lacp-rate=30secs
[admin@MikroTik] >

i don't know what exactly balance-xor used for
Last edited by jagowan on Thu Aug 02, 2007 12:45 pm, edited 1 time in total.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 12:43 pm

No, I'm not asking about router interface, but I'm asking for the second device that terminates bonding interface on the other end (Is it switch ?).
As you need second end device for bonding, it does not work with bonding configured only on one router.
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 12:48 pm

No, I'm not asking about router interface, but I'm asking for the second device that terminates bonding interface on the other end (Is it switch ?).
Hmmm... i think switch
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 12:54 pm

I think that bonding is possible only between two routers.
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:02 pm

I'm not sure this is correct configuration or not, i'm just looking for failover with 2 lokal link shown in picture and i found "bonding" documentation in Google. So, i want to try "bonding" methode in my Mikrotik Router. As my subject, i want to know right configuration. Maybe i'm wrong, but i have tested today and seemly working evenly there are unconstantly time for switching from primary link to secondary link. i don't know why, maybe sombody know.

rgrds
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:05 pm

1) Bonding requires two device to work.
2) What is the problem with routing configuration for ether1-intel, ether2-onboard addresses ?
 
User avatar
janisk
MikroTik Support
MikroTik Support
Posts: 6263
Joined: Tue Feb 14, 2006 9:46 am
Location: Riga, Latvia

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:13 pm

i would go with sergejs suggestion with simply routed network.

also, you can create small OSPF network and set up link weights, so, when everything operates - your fiber is used, when fiber fails routes through fiber are removed and your wireless kicks in automatically
 
dada
Member Candidate
Member Candidate
Posts: 245
Joined: Tue Feb 21, 2006 1:44 pm

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:16 pm

we just want to use secondary link (wireless) in emergency only, not for balanced trafic, this day i have configure my Mikrotik Router B with bonding and fail over link can working properly, but.... i can't see the fix delay for switching from primary to secondary link, this is about 1sec until 40sec. I don't know my configuration is correct or not.
Use no bonding. Configure the devices so there will be 2 transparent links between the Catalyst and MT router B. Then try to use STP (Spanning Tree protocol). Better way is to change the topology to have a cisco switch on each side and use RSTP (Rapid STP - much faster convergence = few seconds versus 30seconds+).

Regards
Dalibor Toman
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:20 pm

1) Bonding requires two device to work.
2) What is the problem with routing configuration for ether1-intel, ether2-onboard addresses ?
1) Yes I know
2) We just have single ip addres for WAN (directly to Router A) 192.168.0.2/30
 
User avatar
janisk
MikroTik Support
MikroTik Support
Posts: 6263
Joined: Tue Feb 14, 2006 9:46 am
Location: Riga, Latvia

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:22 pm

you have to set up rstp-bridge-test for version 2.9 to have RSTP functionality on routerOS

it is called test, because it was introduces into stable version of 2.9 not at actual development of 2.9 version of routeros
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:25 pm

Use no bonding. Configure the devices so there will be 2 transparent links between the Catalyst and MT router B. Then try to use STP (Spanning Tree protocol). Better way is to change the topology to have a cisco switch on each side and use RSTP (Rapid STP - much faster convergence = few seconds versus 30seconds+).

Regards
Dalibor Toman
Hmm, I think this configuration working properly. But i'm not sure if the condition is no RSTP running in other edge (router A or switch catalyst). The problem is, i'm just have on Router B access only. Router A and catalyst i don't have any access
 
dada
Member Candidate
Member Candidate
Posts: 245
Joined: Tue Feb 21, 2006 1:44 pm

Re: how to make failover with bonding?

Thu Aug 02, 2007 1:40 pm

Use no bonding. Configure the devices so there will be 2 transparent links between the Catalyst and MT router B. Then try to use STP (Spanning Tree protocol). Better way is to change the topology to have a cisco switch on each side and use RSTP (Rapid STP - much faster convergence = few seconds versus 30seconds+).
Hmm, I think this configuration working properly. But i'm not sure if the condition is no RSTP running in other edge (router A or switch catalyst). The problem is, i'm just have on Router B access only. Router A and catalyst i don't have any access
In the case it may be impossible to create working redundant link.
You have to change routerA an Catalyst settings to use OSPF (different VLAns for main and bakup link and new interface on routerA) or for STP link you have to be sure the Catalysts ports 2 a 3 use STP (and you may require to define STP cost on one of them too - it depends where you want to have port blocked)

Regards
Dalibor Toman
 
User avatar
jagowan
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 50
Joined: Wed Apr 04, 2007 5:34 am

Re: how to make failover with bonding?

Thu Aug 02, 2007 2:13 pm

In the case it may be impossible to create working redundant link.
You have to change routerA an Catalyst settings to use OSPF (different VLAns for main and bakup link and new interface on routerA) or for STP link you have to be sure the Catalysts ports 2 a 3 use STP (and you may require to define STP cost on one of them too - it depends where you want to have port blocked)

Regards
Dalibor Toman
thanks for opinions,
If I possible to change configuration on Catalyst or Router A, maybe i will use STP bridge mode :) .That's my problem, we must have 2 local link for redundant link but we just have access in Router B side. So, I can't use STP in 1 side as i know.

Who is online

Users browsing this forum: alixviral, D3nkis, mkx, sas2k and 171 guests