Jump to content
Sign in to follow this  
wlessard

Routing/Network etc

Recommended Posts

As I said, it depends what you're using, so if iptables, this is what you need to do:

 

From here:

 

http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch14_:_Linux_Firewalls_Using_iptables#Masquerading_.28Many_to_One_NAT.29

 

iptables -A POSTROUTING -t nat -o eth0 -s 192.168.1.0/24 -d 0/0 -j MASQUERADE

 

assuming that eth0 is your internet connection, because you mentioned eth1 is your internal network. Replace the IP address with your internal network if it's different.

 

Check if your machines can then access the internet or simply from a machine do:

 

ping 8.8.8.8

 

and if it replies, that means it's working. Then to save it:

 

service iptables save

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...