Ok, a rather confusing subject... fairly simple question though..
Kernel 2.2 server. I have 2 network cards. They both have a default route (though the route used by internally generated traffic is NIC1), and they are both public IP addresses. And, can both ping a public third external host fine (ping -I<ethx> <host>. They are on different networks.
If I connect (ssh) to the second NIC IP from a unknown third network that isn't on EITHER network including the NICS, it will try to return the outbound traffic via the default gw of the first NIC (the global default route). Is there some way to force the outbound reply traffic to go back out the way it came in (control the externally generated traffic)? I'd still want outbound originating traffic to leave via the regular default route gateway.
I guess what I need is a way to filter the packets such that outbound return traffic goes back out the adapter it arrived on but outbound originating traffic goes out the regular normal default gw. Statefull routing??