* Problem with 2 NAT and 2 ROUTE
@ 2004-08-23 14:42 Cristian Seva (VOIPLAB)
2004-08-24 5:17 ` Jose Maria Lopez
0 siblings, 1 reply; 5+ messages in thread
From: Cristian Seva (VOIPLAB) @ 2004-08-23 14:42 UTC (permalink / raw)
To: netfilter
have a problem with mi linux BOX
Eth0 = 192.168.0.254 (RED A)
Eth1 = 200.69.123.177/130 (LINK A)
Eth2 = 192.168.0.100 (RED B)
Eth3 = 192.168.1.1 para el PPPOE
ppp0= DynamicIP (LINK B)
-------------------------------------------------------------------
-DEFAULT ROUTE
200.69.123.178 (LINKA)
ppp0 (cdo establece el PPPOE)
-------------------------------------------------------------------
-IPTABLES NAT RULES
iptables -t nat -A POSTROUTING -s 192.168.0.0/255.255.255.128 -o ppp0 -j
MASQUERADE
iptables -t nat -A POSTROUTING -s 192.168.0.128/255.255.255.128 -o eth1 -j
MASQUERADE
-------------------------------------------------------------------
My problem is the only NAT works is the NAT with march with de default
route..
Can any one helme?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Problem with 2 NAT and 2 ROUTE
2004-08-23 14:42 Problem with 2 NAT and 2 ROUTE Cristian Seva (VOIPLAB)
@ 2004-08-24 5:17 ` Jose Maria Lopez
0 siblings, 0 replies; 5+ messages in thread
From: Jose Maria Lopez @ 2004-08-24 5:17 UTC (permalink / raw)
To: netfilter
El lun, 23 de 08 de 2004 a las 16:42, Cristian Seva (VOIPLAB) escribió:
> have a problem with mi linux BOX
>
> Eth0 = 192.168.0.254 (RED A)
> Eth1 = 200.69.123.177/130 (LINK A)
> Eth2 = 192.168.0.100 (RED B)
> Eth3 = 192.168.1.1 para el PPPOE
> ppp0= DynamicIP (LINK B)
> -------------------------------------------------------------------
> -DEFAULT ROUTE
> 200.69.123.178 (LINKA)
> ppp0 (cdo establece el PPPOE)
> -------------------------------------------------------------------
> -IPTABLES NAT RULES
> iptables -t nat -A POSTROUTING -s 192.168.0.0/255.255.255.128 -o ppp0 -j
> MASQUERADE
> iptables -t nat -A POSTROUTING -s 192.168.0.128/255.255.255.128 -o eth1 -j
> MASQUERADE
> -------------------------------------------------------------------
>
> My problem is the only NAT works is the NAT with march with de default
> route..
>
> Can any one helme?
>
I think you need Advanced Routing using iproute2 nexthop facility
to send the traffic to both routers, and then masquerade the
connections, masquerading does know who to send the traffic but
it doesn't know how to do it.
--
Jose Maria Lopez Hernandez
Director Tecnico de bgSEC
jkerouac@bgsec.com
bgSEC Seguridad y Consultoria de Sistemas Informaticos
http://www.bgsec.com
ESPAÑA
The only people for me are the mad ones -- the ones who are mad to live,
mad to talk, mad to be saved, desirous of everything at the same time,
the ones who never yawn or say a commonplace thing, but burn, burn, burn
like fabulous yellow Roman candles.
-- Jack Kerouac, "On the Road"
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: problem with 2 NAT and 2 ROUTE
@ 2004-08-24 12:13 Jason Opperisano
0 siblings, 0 replies; 5+ messages in thread
From: Jason Opperisano @ 2004-08-24 12:13 UTC (permalink / raw)
To: netfilter
> I have a problem with mi linux BOX
> .
> Eth0 = 192.168.0.254 (RED A)
> Eth1 = 200.69.123.177/130 (LINK A)
> Eth2 = 192.168.0.100 (RED B)
> Eth3 = 192.168.1.1 para el PPPOE
> ppp0= DynamicIP (LINK B)
> -------------------------------------------------------------------
> DEFAULT ROUTE
> 200.69.123.178 (LINKA)
> ppp0 (cdo establece el PPPOE)
> -------------------------------------------------------------------
> IPTABLES NAT RULES
> iptables -t nat -A POSTROUTING -s 192.168.0.0/255.255.255.128 -o ppp0 -j MASQU
ERADE
> iptables -t nat -A POSTROUTING -s 192.168.0.128/255.255.255.128 -o eth1 -j MAS
QUERADE
>
> -------------------------------------------------------------------
>
> My problem is the only NAT works is the NAT with march with de default route..
>
> Can any one helme?
you need to add a policy route thats routes traffic from 192.168.0.128/25 via the eth1 (ppp1, maybe?) interface.
have a look at:
http://lartc.org/howto/lartc.rpdb.html
-j
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Problem with 2 NAT and 2 ROUTE
@ 2004-08-24 5:24 Jose Maria Lopez
0 siblings, 0 replies; 5+ messages in thread
From: Jose Maria Lopez @ 2004-08-24 5:24 UTC (permalink / raw)
To: netfilter@lists.netfilter.org
El lun, 23 de 08 de 2004 a las 16:42, Cristian Seva (VOIPLAB) escribió:
> have a problem with mi linux BOX
>
> Eth0 = 192.168.0.254 (RED A)
> Eth1 = 200.69.123.177/130 (LINK A)
> Eth2 = 192.168.0.100 (RED B)
> Eth3 = 192.168.1.1 para el PPPOE
> ppp0= DynamicIP (LINK B)
> -------------------------------------------------------------------
> -DEFAULT ROUTE
> 200.69.123.178 (LINKA)
> ppp0 (cdo establece el PPPOE)
> -------------------------------------------------------------------
> -IPTABLES NAT RULES
> iptables -t nat -A POSTROUTING -s 192.168.0.0/255.255.255.128 -o ppp0
-j
> MASQUERADE
> iptables -t nat -A POSTROUTING -s 192.168.0.128/255.255.255.128 -o
eth1 -j
> MASQUERADE
> -------------------------------------------------------------------
>
> My problem is the only NAT works is the NAT with march with de default
> route..
>
> Can any one helme?
>
I think you need Advanced Routing using iproute2 nexthop facility
to send the traffic to both routers, and then masquerade the
connections, masquerading does know who to send the traffic but
it doesn't know how to do it.
--
Jose Maria Lopez Hernandez
Director Tecnico de bgSEC
jkerouac@bgsec.com
bgSEC Seguridad y Consultoria de Sistemas Informaticos
http://www.bgsec.com
ESPAÑA
The only people for me are the mad ones -- the ones who are mad to live,
mad to talk, mad to be saved, desirous of everything at the same time,
the ones who never yawn or say a commonplace thing, but burn, burn, burn
like fabulous yellow Roman candles.
-- Jack Kerouac, "On the Road"
^ permalink raw reply [flat|nested] 5+ messages in thread* problem with 2 NAT and 2 ROUTE
@ 2004-08-23 14:38 Cristian Seva (VOIPLAB)
0 siblings, 0 replies; 5+ messages in thread
From: Cristian Seva (VOIPLAB) @ 2004-08-23 14:38 UTC (permalink / raw)
To: netfilter
[-- Attachment #1.1: Type: text/plain, Size: 781 bytes --]
I have a problem with mi linux BOX
.
Eth0 = 192.168.0.254 (RED A)
Eth1 = 200.69.123.177/130 (LINK A)
Eth2 = 192.168.0.100 (RED B)
Eth3 = 192.168.1.1 para el PPPOE
ppp0= DynamicIP (LINK B)
-------------------------------------------------------------------
DEFAULT ROUTE
200.69.123.178 (LINKA)
ppp0 (cdo establece el PPPOE)
-------------------------------------------------------------------
IPTABLES NAT RULES
iptables -t nat -A POSTROUTING -s 192.168.0.0/255.255.255.128 -o ppp0 -j MASQUERADE
iptables -t nat -A POSTROUTING -s 192.168.0.128/255.255.255.128 -o eth1 -j MASQUERADE
-------------------------------------------------------------------
My problem is the only NAT works is the NAT with march with de default route..
Can any one helme?
[-- Attachment #1.2: Type: text/html, Size: 2175 bytes --]
[-- Attachment #2: diagrama.jpg --]
[-- Type: image/jpeg, Size: 16659 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2004-08-24 12:13 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-23 14:42 Problem with 2 NAT and 2 ROUTE Cristian Seva (VOIPLAB)
2004-08-24 5:17 ` Jose Maria Lopez
-- strict thread matches above, loose matches on Subject: below --
2004-08-24 12:13 problem " Jason Opperisano
2004-08-24 5:24 Problem " Jose Maria Lopez
2004-08-23 14:38 problem " Cristian Seva (VOIPLAB)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox