rutare

Gabos Denes gabosdenes la gmail.com
Dum Oct 14 19:27:09 BST 2007


Eu pot descarca pe router fara probleme, pot accesa routerul din afara 
pe ambele ip-uri, numai din interior nu pot pe interfatele externe. Nu 
vad ce as rezolva daca as sterge linia cu stersul rutei default, defapt 
fara aia as avea 2 route default una catre un provider si una multipath.

Deni

Gabi Botosan wrote:
> Salut
>
> Comenteaza linia cu stersul rutelor;
> si eu am o problema asemanatoare, am 2 provideri ca si tine si nu pot 
> descarca nimic de pe net pe router insa ma pot conecta la router si 
> asta abia dupa ce am comentat lina aceea; daca primesti o rezolvare la 
> problema ta te rog sa imi spui si mie raspunsul
>
> Numai de bine... Gabi
> */
>
>
> Gabos Denes <gabosdenes at gmail.com>/* wrote:
>
>     Salutare la toti utilizatorii Ubuntu
>
>     Am o problema legata de rutare. Am 2 provideri de internet si
>     vreau sa
>     fac sa mearga netul pe amindoua deodata. Am urmat pasii de pe
>     http://lartc.org/howto/lartc.rpdb.multiple-links.html ... si totul
>     merge
>     ok inafara de faptul ca din interiorul retelei nu pot accesa
>     serverul pe
>     ip-urile externe (nici cu firewallul dat jos :p). Reteaua interna
>     este
>     mascaradata pe ambele ip-uri externe.
>
>     Aici este scriptul care face rutarea:
>     P1_NET P2_NET reteaua cu providerii
>     IP1 IP2 ip-urile externe
>     P1_GW P2_GW gatewayul de la provideri
>
>
>     #!/bin/sh
>     ip route del default
>
>     #LAN
>     P0_NET=192.168.0.0
>     IF0=eth0
>     IP0=192.168.0.1
>
>     #UPC
>     P1_NET=x.x.134.0
>     IF1=eth2
>     IP1=X.X.134.218
>     P1_GW=X.X.134.1
>
>     #RDS
>     P2_NET=X.X.123.192
>     IF2=eth1
>     IP2=X.X.123.220
>     P2_GW=X.X.123.193
>
>     ip route add $P1_NET dev $IF1 src $IP1 table UPC
>     ip route add default via $P1_GW table UPC
>     ip route add $P2_NET dev $IF2 src $IP2 table RDS
>     ip route add default via $P2_GW table RDS
>
>     ip route add $P1_NET dev $IF1 src $IP1
>     ip route add $P2_NET dev $IF2 src $IP2
>
>     #Next, you set up the routing rules. These actually choose what
>     routing
>     #table to route with. You want to make sure that you route out a given
>     #interface if you already have the corresponding source address:
>     ip rule add from $IP1 table UPC
>     ip rule add from $IP2 table RDS
>
>
>     #'If $P0_NET is the local network and $IF0 is its interface,
>     #the following additional entries are desirable:
>     ip route add $P0_NET dev $IF0 src $IP0 table UPC
>     ip route add $P2_NET dev $IF2 table UPC
>     ip route add 127.0.0.0/8 dev lo table UPC
>     ip route add $P0_NET dev $IF0 src $IP0 table RDS
>     ip route add $P1_NET dev $IF1 table RDS
>     ip route add 127.0.0.0/8 dev lo table RDS
>
>     ip route del default
>     ip route add default scope global nexthop via $P1_GW dev eth2
>     weight 1
>     nexthop via $P2_GW dev eth1 weight 1
>     ip route flush cache
>
>
>     -- 
>     ubuntu-ro mailing list
>     ubuntu-ro at lists.ubuntu.com
>     https://lists.ubuntu.com/mailman/listinfo/ubuntu-ro
>
>
> ------------------------------------------------------------------------
> Building a website is a piece of cake.
> Yahoo! Small Business gives you all the tools to get online. 
> <http://us.rd.yahoo.com/evt=48251/*http://smallbusiness.yahoo.com/webhosting/?p=PASSPORTPLUS> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.ubuntu.com/archives/ubuntu-ro/attachments/20071014/50393424/attachment.htm 


Mai multe informații despre lista de discuții ubuntu-ro