LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 09-09-2001, 12:24 PM   #1
oUTLAw
LQ Newbie
 
Registered: Sep 2001
Location: Austria
Distribution: SuSE 8.0
Posts: 18

Rep: Reputation: 0
Question gateway


Hi Linux Gurus!!!





























I'm using 2 Linux PCs (i386).














One of them has to become a Internet Gateway machine, so i can go with the other one over the LAN into the Internet.





























- Kernel 2.4.7














- Machine i386














- Linux SuSE 7.0





























BUT, how can I manage this???
























Please help!!!

 
Old 09-09-2001, 12:34 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
You'll just need to turn on IP Masqurading and set ipchains up properly.

in my gateway's /etc/rc.local i have...

/sbin/ipchains -A forward -i ppp0 -j MASQ
echo 1 > /proc/sys/net/ipv4/ip_forward

these two lines enable the internal network to communicate with the modem interface ppp0. This is a very simple low level version, and you might want a whole lot more config in ipchains, but it does the job for me.

you should now be able to ping the ouitside world from the LAN.

next you need to set the gaetway on your remote machine. This can be done in linuxconf, or by adding the line

gateway="xxx.xxx.xxx.xxx"

in the /etc/sysconfig/network-scripts/ifcfg-ethX file where X is the interface connected to the lan. probably 0. oh and replace all those x's with the gateways' IP.

That's the bare essentials really. Remeber to set up DNS servers in /etc/resolv.conf and that's about it...

There are handy things like mserver available which sorts out remote modem dialling etc...
 
Old 09-09-2001, 01:16 PM   #3
oUTLAw
LQ Newbie
 
Registered: Sep 2001
Location: Austria
Distribution: SuSE 8.0
Posts: 18

Original Poster
Rep: Reputation: 0
BUT if I run "/sbin/ipchains -A forward -i ppp0 -j MASQ" command, I become an error back: "Protocol not available" ????
 
Old 09-10-2001, 08:01 AM   #4
Steave
Member
 
Registered: Jul 2001
Location: Braunschweig, Germany
Distribution: Suse 7.2
Posts: 184

Rep: Reputation: 30
ppp0 might not be the right interface. connect to the internet and run ifconfig on the machine that's connected to the internet.
This should display infos about your ethernet-devices and internet device. Might also be something like ippp0 or the alike.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
lm10.0 gateway is set but when I reboot I have to set the gateway rharvey32 Mandriva 8 02-13-2006 01:35 PM
What is a gateway? can I have more than one gateway on a vlan? abefroman Linux - Networking 3 09-06-2005 10:43 AM
Need for a gateway? ThePlague Linux - Networking 2 12-27-2004 06:59 PM
Odd problem: Gateway unreachable after certain amount of time (Win XP Gateway) SocialEngineer Linux - Networking 2 08-13-2004 12:54 AM
What is this ??? Gateway or NOT ??? Lilltjalle Mandriva 3 11-30-2003 11:10 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:25 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration