internet sharing
This is a discussion about internet sharing in the Everything Linux category; hello, how can i configure my linux to share internet. my computer that has an internet has lancards on it. i do not hav a router or any device other than the lancard. im using fedora core 4. in windows it is easy to share internet connection, is it also easy on linux??? maybe someone can point me to some tutorials ...
hello, how can i configure my linux to share internet. my computer that has an internet has lancards on it. i do not hav a router or any device other than the lancard. im using fedora core 4. in windows it is easy to share internet connection, is it also easy on linux??? maybe someone can point me to some tutorials on it.
tnx
tnx
Participate in our website and join the conversation
This subject has been archived. New comments and votes cannot be submitted.
Nov 14
Dec 6
0
1 minute
Responses to this topic
Is this dialup, cable or DSL?
How many machines are you looking to set up?
If you have a cable or DSL connection, how many ethernet ports are on the modem?
If you have cable, does the ISP assign addresses statically or dynamically?
Knowing youe specific needs will help answer your question.
How many machines are you looking to set up?
If you have a cable or DSL connection, how many ethernet ports are on the modem?
If you have cable, does the ISP assign addresses statically or dynamically?
Knowing youe specific needs will help answer your question.
I expect you have ONE PC with TWO ethernet cards(interfaces). One goes to the other computer and one goes to the Internet.
Example situation:
[font:Courier]eth0 - to 2nd computer, IP 192.168.0.1
[font:Courier]eth1 - to Internet, IP 10.64.1.99
Let's do this on the computer in console (as root):
[font:Courier] echo "1" > /proc/sys/net/ipv4/ip_forward
(or permanently, add this line to [font:Courier]/etc/rc.d/rc.local
OR set it in [font:Courier]/etc/sysctl.conf (esp. in RH/Fedora))
[font:Courier]/sbin/iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
Then, on the 2nd computer, you have to:
- set default gateway to 192.168.0.1
- set up the same DNS servers as on the 1st computer
You may enter fixed IP as well (eg. 192.168.0.2) or keep it on DHCP.
I have just set up this succesfully. If I didn't write something clear, you may ask me at: brozkeff-AT-gmail-DOT-com
_____________
Brozkeff
Example situation:
[font:Courier]eth0 - to 2nd computer, IP 192.168.0.1
[font:Courier]eth1 - to Internet, IP 10.64.1.99
Let's do this on the computer in console (as root):
[font:Courier] echo "1" > /proc/sys/net/ipv4/ip_forward
(or permanently, add this line to [font:Courier]/etc/rc.d/rc.local
OR set it in [font:Courier]/etc/sysctl.conf (esp. in RH/Fedora))
[font:Courier]/sbin/iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
Then, on the 2nd computer, you have to:
- set default gateway to 192.168.0.1
- set up the same DNS servers as on the 1st computer
You may enter fixed IP as well (eg. 192.168.0.2) or keep it on DHCP.
I have just set up this succesfully. If I didn't write something clear, you may ask me at: brozkeff-AT-gmail-DOT-com
_____________
Brozkeff