+ Responder ao Tópico



  1. Gostaria de direcionar cada rede para um gateway diferente.

    Cenario:

    Gateways:
    192.168.1.1
    192.168.2.1

    Redes:
    192.168.20.0/24 - sair por 192.168.1.1
    192.168.21.0/24 - sair por 192.168.2.1

    Fiz através de marcação de pacotes, mas não está funcionando

    / ip firewall mangle

    add chain=prerouting src-address=192.168.20.0/24 protocol=tcp routing-mark=link1 action=mark-routing new-routing-mark=link1 \
    passthrough=yes comment="" disabled=no
    add chain=prerouting src-address=192.168.20.0/24 protocol=udp routing-mark=link1 action=mark-routing new-routing-mark=link1 \
    passthrough=yes comment="" disabled=no

    add chain=prerouting src-address=192.168.21.0/24 protocol=tcp routing-mark=link2 action=mark-routing new-routing-mark=link2 \
    passthrough=yes comment="" disabled=no
    add chain=prerouting src-address=192.168.21.0/24 protocol=udp routing-mark=link2 action=mark-routing new-routing-mark=link2 \
    passthrough=yes comment="" disabled=no


    / ip route
    add dst-address=0.0.0.0/0 gateway=192.168.1.1 scope=255 target-scope=10 routing-mark=link1 comment="" disabled=no

    add dst-address=0.0.0.0/0 gateway=192.168.2.1 scope=255 target-scope=10 routing-mark=link2 comment="" disabled=no

  2. / ip firewall mangle
    add chain=prerouting src-address=0.0.0.0/24"rede que vc quer q saia" action=mark-routing new-routing-mark=gtw1 passthrough=no comment="" \
    disabled=no
    add chain=prerouting src-address=0.0.0.0./24"rede que vc quer q saia" action=mark-routing new-routing-mark=gtw2 passthrough=no \
    comment="" disabled=no

    / ip route
    add dst-address=0.0.0.0/0 gateway=30.30.30.1 scope=255 target-scope=10 routing-mark=lgtw1 comment="" disabled=no
    add dst-address=0.0.0.0/0 gateway=30.30.30.1 scope=255 target-scope=10 routing-mark=gtw2 comment="" disabled=no



  3. Citação Postado originalmente por edevaldo Ver Post
    / ip firewall mangle
    add chain=prerouting src-address=0.0.0.0/24"rede que vc quer q saia" action=mark-routing new-routing-mark=gtw1 passthrough=no comment="" \
    disabled=no
    add chain=prerouting src-address=0.0.0.0./24"rede que vc quer q saia" action=mark-routing new-routing-mark=gtw2 passthrough=no \
    comment="" disabled=no

    / ip route
    add dst-address=0.0.0.0/0 gateway=30.30.30.1 scope=255 target-scope=10 routing-mark=lgtw1 comment="" disabled=no
    add dst-address=0.0.0.0/0 gateway=30.30.30.1 scope=255 target-scope=10 routing-mark=gtw2 comment="" disabled=no
    Opa Edivaldo...

    Estou utilizando o MK 2.9.27 Crack, a regra as vezes para de funcionar do nada... Vou baixar o MK 3.3 e deixar testando...






Tópicos Similares

  1. Um IP da rede sair por outro gatway
    Por weslleyr.vieira no fórum Redes
    Respostas: 2
    Último Post: 05-11-2013, 16:43
  2. Respostas: 22
    Último Post: 02-11-2010, 17:51
  3. Respostas: 1
    Último Post: 01-07-2010, 21:06
  4. Respostas: 0
    Último Post: 17-03-2008, 11:27
  5. Sair por um especificado ip.
    Por pearljam no fórum Redes
    Respostas: 1
    Último Post: 17-06-2007, 12:52

Visite: BR-Linux ·  VivaOLinux ·  Dicas-L