zehome / MLVPN

Multi-link VPN (ADSL/SDSL/xDSL/Network aggregation / bonding)
http://www.mlvpn.fr/
BSD 2-Clause "Simplified" License
520 stars 126 forks source link

Only One interface/tunnel is used, loadbalance issue #118

Closed marc494 closed 5 years ago

marc494 commented 5 years ago

I compiled MLVPN from source (latest version) both client and the server (Debian 9.6). In my setup I have a firewall with 2X 20/20 mbps configured. Without MLVPN the total throughput is ~950mbps.

But when I have both MLVPN tunnels (5080 and 5081) connected, I get only 20mbps at IPERF3. Also when I make a pcap at the MLVPN, I see only the many traffic (the iperf3-test) at port 5080 and at port 5081 a little bit tunnel traffic (2 packets per 2 seconds), but not the iperf3-test.

I have checked both port 5080 and 5081 with a single tunnel and it is working correct, so no routing/firewall issue. It seems a load-balance issue.

Do I have to change something in my config file?

Both links are connected with the following setup:

image001

Thanks in advance!

server.txt client.txt

zehome commented 5 years ago

Try setting bandwidth_upload to the same value on both tunnels on both side, to a non zero value.

Don't expect to have Gbps speed with mlvpn, it's not designed for that

marc494 commented 5 years ago

I have change the setting bandwidth_upload, but I get still the same result (20mbps) I understand that I don´t get gbps speed, but I don´t think 2X 20mbps=40mbps over ethernet is a problem.

zehome commented 5 years ago

I don't understand your setup. Why do you want to do multiple tunnels if you have only one eth interface/ip on each side ?

marc494 commented 5 years ago

I want just test the bandwidth-bundle from client to server. With a firewall I can control the traffic bandwidth, so I give 20/20 to destination port 5080 (tunnel 1) and 20/20 to tunnel2. Both I need to have 40/40. Because this config is in LAN (LAN-to-LAN) the speed is always the same. When this lan-lan bundel is working I will test it with 4G (which has no fixed speed)

But because the bundel is not working in this test environment, it is not going work in a real-environment.

marc494 commented 5 years ago

I have also tried with 2 eth-interfaces at the client, but I get the same result (only 20mbps, with both tunnels connected).

zehome commented 5 years ago

Try a tcpdump or run with debug mode to get more information on what mlvpn is doing.

It's not going to work with a variable speed 4g link anyway.

marc494 commented 5 years ago

I have found the issue, it was the option loss_tolerence. But in the documentation I read ¨If you have a high latency 3G/4G link and a DSL connection, then adjust reorder_buffer_size to a reasonable value to get good performance.¨ Is it possible to have a LAN from 20/20 and one 4G from 70/70 = and have arround 90/90mbps

zehome commented 5 years ago

You can try, but I bet you'll get nowere near what you would expect. 4G is constantly changing bandwidth and the static roundrobin used by mlvpn just won't be enough.

marc494 commented 5 years ago

But when I have the following situation: LAN: 10/10 (fixed) WWAN: 30/30 (software fixed)

To what value should I change the reorder_buffer_size. And are the more settings I can change to get arround ~40/40mbps as bundle?

zehome commented 5 years ago

disable the reorder system to get the best results.

marc494 commented 5 years ago

I have disabled the system and it is working perfect! Thanks!