Another routing problem

I have 3 Linux machines(Debian woody) A,B,C.
A and B are in same network.
C is in diffrent network.
I want to use B as the gateway for A for connecting to the C network.
-------------------------------------------------
A and B are in 192.168.1.0 network
A IPaddress - 192.168.1.2
Netmask 255.255.255.0

No I want to use my Machine B as Gateway for A to access the other network.
For this In Machine A in the routing entry I added

route add -net 192.168.0.0 netmask 255.255.255.0 gateway 192.168.1.1 dev eth0.
But I cud not ping or ssh to C from A .From C also I cud not ping to A .But I can access Machine B .
Why?.Am i did anything wrong?.

The MCTS: Microsoft Exchange Server 2010 certification validates your skills in supporting the maintenance and administration of the Exchange servers in an enterprise environment. Learn everything you need to know with this course.

jviko,
what does the
echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp
command ?

0

palanisaravananAuthor Commented: 2004-03-23

Jviko
I don't want to use machine B as gateway for both the networks.
MY situation is
Machine B should be the gateway for all the outgoing packets sent from
Machine A to the other network i.e Machine C .
I know it is possible.It involves a bit of route command.There only I am struggling.