Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
12-12-2002, 09:24 AM
|
#1
|
|
LQ Newbie
Registered: Nov 2002
Location: france
Distribution: redhat8.0 and mandrake9.0
Posts: 22
Rep:
|
internet connection on linux
hi
i am new in Linux, i used winnt4.0 to share internet in my local network, now i want to use Linux as a local server instead of winnt to connect to the internet and share it to the other computer in my local network. so i would like to know with programms should i use witch files should be configured in order to connect to the internet with Linux and share it.
i have a modem connected to a router that is connected to the computer using ethernet card and another ethernet card for the local network eth1. i have a permanant connection with a fix ip. i configured the 2 cards but i still can't connect to the internet
so please help me
thank you
|
|
|
|
12-12-2002, 09:29 AM
|
#2
|
|
Senior Member
Registered: Apr 2001
Location: Cornwall, England.
Distribution: Debian + Ubuntu
Posts: 4,345
Rep:
|
Am I right in thinking that your setup is like this?
Code:
Internet --> Router --> Linux Box --< Rest of network
If so, then you will want your Linux box configured so that eth0 is on one ip group and eth1 is on another, you would then set your Windows boxes to connect via (proxy?) your Linux box's eth1 ip address. Lots of people will suggest that you use dhcp for the internal, local network (of with your Linux box's eth1 will be a part of), but I maintain that if you're on a very small network (< 10 machines), it is just a easy to maintain if you give each one a seperate IP address.
HTH
|
|
|
|
12-12-2002, 09:39 AM
|
#3
|
|
LQ Newbie
Registered: Nov 2002
Location: france
Distribution: redhat8.0 and mandrake9.0
Posts: 22
Original Poster
Rep:
|
sorry but u seem that u misundertood me , I couldn't connect to internet now , the eth1 have as ip 193.92.100.66 & is connected to the router which have an ip 193.92.100.65 ( i think that is the gateway ) & the nameserver of my isp ( i put them as the forwards in named.conf ) but the answer by ping to any host like www.google.fr is always "network unrecheable " & in the status bar of mozilla is first resolving hostname & now sending request but process isn't answering
thanks
|
|
|
|
12-12-2002, 09:44 AM
|
#4
|
|
Senior Member
Registered: Apr 2001
Location: Cornwall, England.
Distribution: Debian + Ubuntu
Posts: 4,345
Rep:
|
Sorry... I did misunderstand. I have not run into problems like this, myself, so please ignore my above post. Sorry I can't help.
|
|
|
|
12-12-2002, 04:59 PM
|
#5
|
|
LQ Newbie
Registered: Nov 2002
Location: Melb, Oz
Distribution: RH 9, Solaris 9
Posts: 9
Rep:
|
Is it just name resolution that doesn't work? Can you ping an IP address for example ( www.google.fr - 216.239.37.101) . If you cant then you need to see at what point you are getting stuck at. The way I do this is do a ping to each point out of your network until you find the address that is not responding, then investigate from there. At least then you will have narrowed down your problem to one spot.
Craig
|
|
|
|
12-12-2002, 06:02 PM
|
#6
|
|
LQ Newbie
Registered: Nov 2002
Location: france
Distribution: redhat8.0 and mandrake9.0
Posts: 22
Original Poster
Rep:
|
i can ping in my local network but when i try to ping outside (internet) i have a message that said "destination host unreachable"
so i am asking if something to be done to connect to the internet . i configured the 2 ethernet cards one for the local network and the other to connect to the internet .
as i said above i used this configuration modem -> router (193.96.X.X) ->(193.96.X.X+1) linux (redhat8) 192.168.0.3
|
|
|
|
12-12-2002, 06:35 PM
|
#7
|
|
LQ Newbie
Registered: Nov 2002
Location: Melb, Oz
Distribution: RH 9, Solaris 9
Posts: 9
Rep:
|
Ok. Here are a few things to look at
Have you put a route in place from one network card to the other on the Linux box? I am not sure exactly on the syntax (I am still new to Linux as well) but do a man route it it will show you some examples.
Do you have a FW (iptables?) running on the Linux box? Maybe this is blocking your access out. Maybe turn it off temporarily to verify a connection?
If you either telnet or console into your router can you verify that you can ping the internet from there. If you cant then the Linux box may not be your problem.
Craig
|
|
|
|
12-13-2002, 12:18 PM
|
#8
|
|
Member
Registered: Feb 2002
Location: Orlando
Distribution: Whatever I feel like at the time I install.
Posts: 284
Rep:
|
OK the way I see it is that you have everything setup except for the linux box. You need to be using either ipchains or iptables. I personally like iptables better and it is what replaced ipchains.
You should create a file that you execute on startup that will autostart these functions.
You also need to enable IP Forwarding by this line:
echo 1 > /proc/sys/net/ipv4/ip_forward
You also need these lines to forward traffic between NICs:
iptables -t nat -I POSTROUTING -p all -d 0/0 -s 0/0 -j SNAT --to-source xxx.xxx.xxx.xxx (ext IP address)
if you e-mail my i will send you a copy of my script (too big for here)
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 07:12 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|