how to force iproute2 to FORWARD to another interface packets with
I have this situation:
My machine debina, has three interfaces:
eth1 212.126.24.129 ppp0 10.2.0.1 (Point-to-Point: 212.31.242.98) nsc5 10.2.0.250 (Point-to-Point: 172.23.140.32)
I want packets which come in through the nsc5 interface, to be FORWARDED to the ppp0 interface to 212.31.242.98, even when their destination address is 212.126.24.129 (even so this is the IP of eth1 on this machine).
How to achieve that?
Signature · 8 lines
Miernik _____________________________________
/ /
tel.: +48603070983 / / mailto:[email protected]
__________________/___/ ICQ UIN: 4004001
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/Re: [LARTC] how to force iproute2 to FORWARD to another interface
Quoted 9 lines · Jan Macek
I have this situation:
My machine debina, has three interfaces:
eth1 212.126.24.129 ppp0 10.2.0.1 (Point-to-Point: 212.31.242.98) nsc5 10.2.0.250 (Point-to-Point: 172.23.140.32)
Quoted 7 lines
I want packets which come in through the nsc5 interface, to be FORWARDED to the ppp0 interface to 212.31.242.98, even when their destination address is 212.126.24.129 (even so this is the IP of eth1 on this machine).
How to achieve that?
you can use set of 'ip rule' and other routing table
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Re: [LARTC] how to force iproute2 to FORWARD to another interface
In reply to Jan MacekQuoted 6 lines · Wojtek
Quoted 6 lines
My machine debina, has three interfaces:
eth1 212.126.24.129 ppp0 10.2.0.1 (Point-to-Point: 212.31.242.98) nsc5 10.2.0.250 (Point-to-Point: 172.23.140.32)
Quoted 6 lines
Quoted 4 lines
I want packets which come in through the nsc5 interface, to be FORWARDED to the ppp0 interface to 212.31.242.98, even when their destination address is 212.126.24.129 (even so this is the IP of eth1 on this machine).
you can use set of 'ip rule' and other routing table
I tried to, but it is not that simple:
The routing table 'local' is bound to the first rule (rule 0), and I cannot put any other rule before it.
I cannot delete the rule 0.
I tried deleting rules from from the local table, and putting them into table local2, and assinging rule 2 to table local2, but it didn't work
too: I lost connectivity to my local host.
Signature · 8 lines
Miernik _____________________________________
/ /
tel.: +48603070983 / / mailto:[email protected]
__________________/___/ ICQ UIN: 4004001
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/Re: [LARTC] how to force iproute2 to FORWARD to another interface
In reply to Jan MacekYou may want to try the (unoffical) 'ROUTE' netfilter patch (see patch-o-matic at www.netfilter.org)
after applying and re-compiling kernel + iptables use:
iptables -t mangle -A PREROUTING -i nsc5 -d 212.31.242.98 -j ROUTE --iface ppp0
(maybe there is another possibility without recompiling kernel ... but I didn't find anything...)
Quoted 19 lines · Miernik
Quoted 6 lines · Wojtek
Quoted 6 lines
My machine debina, has three interfaces:
eth1 212.126.24.129 ppp0 10.2.0.1 (Point-to-Point: 212.31.242.98) nsc5 10.2.0.250 (Point-to-Point: 172.23.140.32)Quoted 6 lines
Quoted 4 lines
I want packets which come in through the nsc5 interface, to be FORWARDED to the ppp0 interface to 212.31.242.98, even when their destination address is 212.126.24.129 (even so this is the IP of eth1 on this machine).
you can use set of 'ip rule' and other routing table
I tried to, but it is not that simple:
Quoted 9 lines
The routing table 'local' is bound to the first rule (rule 0), and I cannot put any other rule before it.
I cannot delete the rule 0.
I tried deleting rules from from the local table, and putting them into table local2, and assinging rule 2 to table local2, but it didn't work
too: I lost connectivity to my local host.
David Lamparter, [email protected]
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/