[CentOS] Routing local generted packets with fwmark

Fri Oct 15 12:56:31 UTC 2010
Les Mikesell <lesmikesell at gmail.com>

On 10/15/10 3:56 AM, C. L. Martinez wrote:
> On Fri, Oct 15, 2010 at 10:44 AM, John Doe <jdmls at yahoo.com
> <mailto:jdmls at yahoo.com>> wrote:
>     From: C. L. Martinez <carlopmart at gmail.com <mailto:carlopmart at gmail.com>>
>      >>But this doesn't works. This host is CentOS 5.5 based with two interfaces.
>      >Please, any hints?
>     What do you mean by this does'nt work?
>     Nothing works?
>     Half of it?
>     Just in case, but no idea if it is necessary, did you set forwarding?
>     net.ipv4.ip_forward = 1
>     But again, I am not sure it is necessary...
>     JD
> I think I don't need to enable ip forwarding. My problem is when I try to, for
> example, resolve some name address via eth2. My DNS server denies all querys
> because these appears with ip instead of IP.

Is it denying it due to firewalling/configuration, or just doesn't have a route 

> This is one problem. Another problem for example is when I try to synchronize
> host time using ntp service via eth1. Doesn't works.

It seems very strange to need to source from an IP that isn't the one that would 
automatically be chosen by the next-hop route toward the destination, and not 
too surprising that it doesn't work.  Why do you need to do this, and wouldn't 
it be better to nat to the outbound interface if you do?

   Les Mikesell
    lesmikesell at gmail.com