The UNIX Forums
"Join the Network of UNIX System Users"


 
goscript
Newbie
Rank: 1



UID 162
Digest Posts 0
Credits 0
Posts 27
Reading Access 10
Registered Apr 25, 2007
Status Offline
Post at Jun 5, 2007 12:04 PM  Profile | P.M. 
ip routing



ip routing



i am using redhat linux 9, in this box their are two lan intefaces.

eth0 ====> lan
192.168.100.100
255.255.255.0

eth1 ====> internet
static ip
255.255.255.0
59.144.168.226 (gateway)

i want to define a gateway 59.144.168.226 for my lan machines 192.168.100.0/255.255.255.0

so

first i enable ip forward

echo "1" /proc/sys/net/ipv4/ip_forward

second
route ..................... ???

please help me


Top
johno12345
Newbie
Rank: 1



UID 9
Digest Posts 0
Credits 0
Posts 25
Reading Access 10
Registered Apr 25, 2007
Status Offline
Post at Jun 5, 2007 12:05 PM  Profile | P.M. 
you probably mean "echo 1 > /proc/sys/net/ipv4/ip_forward"
your internal lan cant have a public address as a gateway i think , if the lan needs to talk to the outside, one way is to use masquerading at 192.168.100.100 so the gateway needs to be 192.168.100.100 i guess ...
Top
astrovineet
Newbie
Rank: 1



UID 61
Digest Posts 0
Credits 0
Posts 27
Reading Access 10
Registered Apr 25, 2007
Status Offline
Post at Jun 5, 2007 12:05 PM  Profile | P.M. 
corrected earlier post from andryk:


quote:
originally posted by andryk
your internal lan cant have a public address as a gateway i think , if the lan needs to talk to the outside, one way is to use masquerading at 192.168.100.100 so the gateway needs to be 192.168.100.100 i guess ...



correction:

you can certainly have the lan subnet 192.168.100.0 have 59.144.168.226 as a default gateway.

the command would be something like this:


code:
Top
 

 

All times are GMT, the time now is Jul 31, 2010 03:24 AM

Powered by Discuz! 5.0.0  © 2001-2006 UNIX Forums
Processed in 0.004952 second(s), 8 queries

Clear Cookies - Contact Us - UNIX Help - Archiver - WAP