Centos 5.4 : 2 nics 2 gateways

Discussion in 'Installation/Configuration' started by mr_insane, Apr 20, 2010.

  1. mr_insane

    mr_insane New Member

    Hi All,

    Please i want to use 2 external ip adresses for smtp
    I ended up with this solution but it doesn't work

    Please help ?

    ip route add 192.168.3.0/24 dev eth1 src 192.168.3.6 table Adsl1
    ip route add default via 192.168.3.6 table Adsl1
    ip route add 192.168.4.0/24 dev eth2 src 192.168.4.6 table Adsl2
    ip route add default via 192.168.4.6 table Adsl2


    ip route add 192.168.3.0/24 dev eth1 src 192.168.3.6
    ip route add 192.168.4.0/24 dev eth2 src 192.168.4.6


    ip route add default via 192.168.3.1


    ip rule add from 192.168.3.6 table Adsl1
    ip rule add from 192.168.4.6 table Adsl2


    ip route add 192.168.2.0/24 dev eth0 table Adsl1
    ip route add 192.168.4.0/24 dev eth2 table Adsl1
    ip route add 127.0.0.0/8 dev lo table Adsl1
    ip route add 192.168.2.0/24 dev eth0 table Adsl2
    ip route add 192.168.3.0/24 dev eth1 table Adsl2
    ip route add 127.0.0.0/8 dev lo table Adsl2


    ip route add default scope global nexthop via 192.168.3.1 dev eth1 weight 1 \ nexthop via 192.168.4.1 dev eth2 weight 1
     
  2. mr_insane

    mr_insane New Member

    Any Help would be great :)

    Where is the Linux Gurus of this forum ? :(
     
  3. mr_insane

    mr_insane New Member

Share This Page