Author Topic: 2 WAN and 2 LAN configuration help  (Read 2978 times)

hachaboob

  • Zen Apprentice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
2 WAN and 2 LAN configuration help
« on: January 13, 2008, 12:18:11 pm »
Interfaces:
LAN1
LAN2
WAN1(external)
WAN2(external)

What I want to do is route all traffic from LAN1 to the internet through WAN1, and all traffic from LAN2 to the internet through WAN2. Would it be possible to have some kind of fail-over in place?

jcanfield

  • Zen Monk
  • **
  • Posts: 89
  • Karma: +2/-0
    • View Profile
Re: 2 WAN and 2 LAN configuration help
« Reply #1 on: January 13, 2008, 06:14:35 pm »
i haven't actually done this, but here's what it looks like you need to do.

1) Create routes for both interfaces
2) Write a heartbeat script for each LAN interface that monitors the primary WAN.

Check out this link [1], it has all of the moving parts. Not sure how things will tie into ebox.

[1] http://blog.taragana.com/index.php/archive/how-to-load-balancing-failover-with-dual-multi-wan-adsl-cable-connections-on-linux/




« Last Edit: January 13, 2008, 08:08:51 pm by jcanfield »
"Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius...and a lot of courage - to move in the opposite direction."  --  Albert Einstein

hachaboob

  • Zen Apprentice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: 2 WAN and 2 LAN configuration help
« Reply #2 on: January 13, 2008, 11:57:50 pm »
I have looked at the blog and will go down that path if ebox can't help me. I previously used just shorewall/bind9/dhcp3/ntpd but I don't have time to screw around with config files if I can help it :)


Automatic fail-over isn't too important, as long as a quick manual change via the web interface can be done.

sixstone

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1417
  • Karma: +26/-0
    • View Profile
    • Sixstone's blog
Re: 2 WAN and 2 LAN configuration help
« Reply #3 on: January 14, 2008, 09:24:04 am »
eBox allows you to create multipath rules for different gateways. To do so, you need to create two gateways and then create the multigateway rules.

I'm afraid it's not currently implemented the failover mechanism and it's planned to be developed soon.
My secret is my silence...

hachaboob

  • Zen Apprentice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: 2 WAN and 2 LAN configuration help
« Reply #4 on: January 15, 2008, 12:04:56 am »
sixstone, which gateways do i add?

At the moment I have only added WAN1_GW and WAN2_GW to the gateway list. And then to the multi-gateway rules LAN1 -> WAN1_GW, LAN2 -> WAN2_GW. Is that all I have to do? I have noticed that the internet is much slower than it used to be when I was just using Shorewall (same machine).

sixstone

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1417
  • Karma: +26/-0
    • View Profile
    • Sixstone's blog
Re: 2 WAN and 2 LAN configuration help
« Reply #5 on: January 15, 2008, 08:55:57 am »
Yeah, that's all.

Regarding to the speed, have you set any traffic shaping rule?

If not, I don't know what's happening...  :(
My secret is my silence...

hachaboob

  • Zen Apprentice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: 2 WAN and 2 LAN configuration help
« Reply #6 on: January 17, 2008, 06:25:11 am »
i solved the problem. 2! faulty nics! argh! sweet!