iproute2 and kernel 2.2.x NAT

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi there.

I'm trying to implement NAT on a 2.2 kernel using iproute2 according 
to Appendix C of the IP Command Reference that comes with iproute2.

We're also moving to a multiple uplink configuration which 
complicates things a bit.

The kernel is 2.2.27-rc2, built with the various advanced routing 
options (except for large routing tables) turned on.  It seems to be 
working with the multiple path stuff; I've created lookup tables for 
each external interface and the routing is working properly.

I've tried adding a NAT host with "ip route add nat [external ip] via 
[internal ip]" and "ip r sh table local" indicates that the command 
was accepted:

nat [external ip] via [internal ip]  scope host

If I try and ping the NAT ip from the router, I get:

connect: Invalid argument

Not sure if that's expected behavour or not.  The next part is 
tricky; with the multipath routing set up, I want packets from one 
particular internal server to only be NATted if they go out via one 
of the interfaces, but not NATted if they go out via the other.

The "ip rule" syntax allows for a source interface and ip address, 
but not a destination interface.  Is there any way to set this up the 
way I want?

Am I barking up the wrong tree entirely?

----
Nels Lindquist <*>
Information Systems Manager
Morningstar Air Express Inc.

_______________________________________________
LARTC mailing list
LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux