Solved

TC and Iptables - Load balancing 3 providers outbound.

Posted on 2006-10-29
7
476 Views
Last Modified: 2008-01-09
I am looking for a script that can load balance traffic outbound with tc and iptables between three different connections.
I am using nat on the internal interface eth3, and I need to send and balance out to three other connections eth0-2. I would appreciate any help anyone can give me.

0
Comment
Question by:jon37325
  • 2
7 Comments
 
LVL 14

Accepted Solution

by:
pablouruguay earned 250 total points
ID: 17841201
0
 

Author Comment

by:jon37325
ID: 17843320
The only problem is that route and random are not supported anymore in the 2.6 kernel.
0
 
LVL 1

Assisted Solution

by:Paracelsius
Paracelsius earned 250 total points
ID: 17912955
Hi jon37325

instead of -j ROUTE you can MARK the packets an user policy based routing using ip:

ex.:
iptables -t mangle -A PREROUTING -i eth1 -p tcp --sport 1000 -j MARK --set-mark 5

ip route add default via 192.168.0.1 table linkB
ip rule add fwmark 5 table linkB

regards,
pC


0
 

Author Comment

by:jon37325
ID: 17915641
so what would the entire script look like? please give an example.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now