Community discussions

MikroTik App
 
sylhaf
just joined
Topic Author
Posts: 2
Joined: Sat Nov 05, 2022 12:58 pm

Load Balancing through 2 L2TP Tunnel

Sat Nov 05, 2022 1:18 pm

Hello, I'm an absolute beginner so be indulgent.

I have the following setup

Rb5009 with WAN1 and WAN 2 at home
CCR2004 in datacenter

currently, I'm not using WAN2. I have just an L2TP Tunnel through WAN1 to send traffic to the CCR2004

on my rb5009 :
WAN1 -> ether 1 : 192.168.1.2 with gateway 192.168.1.1
WAN2 -> ether 2 : 192.168.50.5 with gateway 192.168.50.1

Goal :
I would like to use both WANs with one tunnel for each I guess (forcing traffic for each specific interface).

I would love to perform a load balancing with these two tunnels for the traffic between these two routers.
I know I ask for much but. I also would like a redundancy. that the link could work with only one WAN if the other one is in failure. I thought about bonding eoip tunnels but the redundancy is not included in this protocol.

As I'm a beginner it could be very helpful to put me some piece of config because I really don't know how to build this.


I would be so happy if I found a solution to this. I think it could benefit other people. if there is already another topic with the solution I would be glad to have the link. but I want to have the beginner perspective here.
 
sindy
Forum Guru
Forum Guru
Posts: 9902
Joined: Mon Dec 04, 2017 9:19 pm

Re: Load Balancing through 2 L2TP Tunnel

Sun Nov 06, 2022 1:22 pm

Hello, I'm an absolute beginner so be indulgent.
In Mikrotik or in networking in general? In any case, this topic doesn't seem to belong to the beginner basics forum to me.

From the high level perspective, you can think of the two L2TP tunnels as of "effective WANs" for the 5009, because that's how you'll actually use them at least for some part of the traffic. So the countless topics dealing with load distribution among multiple WANs cover this part of the task. Since you want both load distribution and redundancy, look for those that work with routing tables preferring one WAN but using the other one as a backup. There are good reasons to use per-connection distribution of traffic rather than per-packet one, so concentrate on solutions that use per-connection-classifier and/or connection marks, not ECMP. ECMP used to be fine when routing cache was available, but that's not the case any more in ROS 7.

From the low level perspective:
  • find out what connection tracking is, what is the purpose and possibilities of connection-mark and routing-mark, and where to assign them - this will make you understand the load distribution solutions
  • find out what routing rules are and how to link a L2TP client interface to a particular WAN (using the src-address of the /interface/l2tp-client row) - you need to make sure that each L2TP tunnel will only use its dedicated WAN on the 5009
  • find out how to monitor the transparency of the tunnel - the native mechanisms of L2TP keep showing the tunnel as up for tens of seconds or even minutes after it stops transporting data
  • for the payload traffic that passes through the L2TP tunnels, do not use NAT on the 5009
 
sylhaf
just joined
Topic Author
Posts: 2
Joined: Sat Nov 05, 2022 12:58 pm

Re: Load Balancing through 2 L2TP Tunnel

Fri Nov 11, 2022 1:18 pm

Hello, first of all, thank you a lot for your answer!
In Mikrotik or in networking in general? In any case, this topic doesn't seem to belong to the beginner basics forum to me.
I think I can say both, I'm an engineer but networking is not my first skill. I'm learning with Mikrotik routers. you may be right, I'm a beginner but the topic is not so "basic"
There are good reasons to use per-connection distribution of traffic rather than per-packet one, so concentrate on solutions that use per-connection-classifier and/or connection marks, not ECMP
Thank you for this overview. it makes me search in good directions for tutorials.

From the low-level perspective :
find out what connection tracking is, what is the purpose and possibilities of connection-mark and routing-mark, and where to assign them - this will make you understand the load distribution solutions
I currently learning all this stuff but it's hard!
you need to make sure that each L2TP tunnel will only use its dedicated WAN on the 5009
I would love to know how to do that! I'm sure there is plenty of tutorials, but as a beginner, I'm a bit lost there for what I'm looking for. it is where an example config would help me a lot!
 
User avatar
BrateloSlava
Member Candidate
Member Candidate
Posts: 132
Joined: Mon Aug 09, 2021 10:33 am
Location: Ukraine, Kharkiv

Re: Load Balancing through 2 L2TP Tunnel

Fri Nov 11, 2022 1:52 pm

Show your current settings in text format. Export them and remove all confidential information from the resulting file.

The task has a simple solution if you have two "white" IP addresses at home and on the remote side. In this case, organize two EOIP channels and combine them into bounding - https://wiki.mikrotik.com/wiki/Manual:Bonding_Examples

Who is online

Users browsing this forum: Google [Bot], robo and 57 guests