Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 04-22-2006, 03:54 AM   #1
deepak rawat
Registered: Apr 2006
Posts: 37

Rep: Reputation: 15
how to share internet with two diff class ip's

i hav one linux box connected to broadband havings ip's on eth0

ip -
netmask -
dns -

and on eth1 ip is

eth1 is connected to local network through a switch or hub

client pc are having windows and linux installed in them coonected to the internet linux box through switch/hub.

i want to share the internet on all this pc's but be sure i am nt interested in squid proxy or any other proxies

i think it was donw through iptables masquerading and if not then plz also let me nw where exactly the iptable masquerading and nat works
Old 04-22-2006, 09:34 AM   #2
Senior Member
Registered: Feb 2002
Location: Szczecin, Poland
Distribution: Gentoo, Debian
Posts: 2,458

Rep: Reputation: 48
Each box where the ip classes change between input and output NICs needs NAT.

You need static NAT as the ip numbers don't change, so use SNAT.

I suggest you have a good look at this iptables tutorial.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Linux to Win share; diff. subnet; thru firewall - not quite there KDoc Linux - Networking 0 08-10-2005 01:59 AM
Two Ip's on one internet connection bugstein Linux - Networking 1 03-18-2005 06:33 AM
how to share /home between diff distros? letdoit Linux - Newbie 2 05-20-2004 07:30 AM
routes, default gateways, ip's internet connecting - Much Stress mudelf Linux - Networking 2 09-29-2003 06:13 PM
class c subnet ip's acid_kewpie General 1 03-12-2002 06:39 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:46 AM.

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