[Gllug] Dual-homed hosts

Pete Ryland pdr at pdr.cx
Thu Dec 6 21:30:20 UTC 2001


It sounds like you already have your routing tables set up.  Bringing the
interfaces up with the right options should do this automatically anyway.

So to make sure that you don't act as a router, you need to make sure
ip_forward is turned off.  You can either make sure that it's not compiled
into your kernel, or (assuming you have /proc filesystem in there) you can
check the status by doing:

cat /proc/sys/net/ipv4/ip_forward 

which should print 0 for off and 1 for on.  To make sure ip_forward is off,
simply do:

echo 0 > /proc/sys/net/ipv4/ip_forward 

There are other ways of achieving the same, but I reckon this is the
easiest.

hope this helps,
Pete

On Thu, Dec 06, 2001 at 09:26:20PM +0000, Dylan Brewis wrote:
> Hi guys,
> 
> When configuring a host on two networks, how should I go about ensuring a
> connection goes via the correct nic? For example, eth0 (192.168.1.1)
> connecting to 192.168.1.0/8 and a gateway to the web; eth1 (192.168.2.1)
> connected to 192.168.2.0/8 - all packets destined from host to 192.168.2.x
> go to eth1, all others to eth0. How do I make sure that the host does not
> route from one interface to the other?
> 
> Cheers
> Dylan

-- 
Gllug mailing list  -  Gllug at linux.co.uk
http://list.ftech.net/mailman/listinfo/gllug




More information about the GLLUG mailing list