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. |
Due to network maintenance being performed by our provider, LQ will be down starting at 05:01 AM UTC. The exact duration of the downtime isn't currently known. We apologize for the inconvenience.
|
 |
08-25-2004, 04:16 AM
|
#1
|
|
Member
Registered: Jul 2003
Location: London
Distribution: Debian, Redhat
Posts: 98
Rep:
|
networking a router and dsl modem problem
Hi All,
I read a bunch of threads on dsl and modems, but I didn't find any solution to my problem, so here goes and sorry if it has been answered already - I just cant find it.
I'm running redhat 7 on a machine that I want to be my network router. I'm going to put iptables on it for a firewall. But before that, I need to get the dsl connection going and it's not happening.
I can't ping my modem. Seems my network cards (eth0 for the internal network and eth1 for the modem) are not configured properly.
I have to set up eth1 to accept a DHCP ip address from the modem, which itself will make the connection to the ISP via PPPoA. But I need to browse the modem itself to set its config via its embedded html.
I can't work out if I messed up the DHCP or the basic eth1 config. A friend at work tells me I have to give the network card the same subnet ip address as the modem, i.e. 192.162.x.x since the modem is already set to 192.162.0.1 (if I remember correctly - I'm at work now and I did this last night at home).
When I run /etc/rc.d/init.d/network start, it currently hangs on init of eth1
But ifconfig shows that eth1 comes up, although without an IP.
My 'route -n' results show nothing relating to the modem or eth1.
Anyone? Thanks
|
|
|
|
08-25-2004, 08:26 AM
|
#2
|
|
Member
Registered: Oct 2003
Location: /illinois/chicago
Distribution: Slackware/Gentoo/FC/RHEL
Posts: 568
Rep:
|
Try this:
Code:
dhcp ethX (where X is your if #)
ifconfig -a
You should now have an IP.
|
|
|
|
08-25-2004, 09:23 AM
|
#3
|
|
Member
Registered: Jul 2003
Location: London
Distribution: Debian, Redhat
Posts: 98
Original Poster
Rep:
|
I'm not at home at the moment to test this, but is that going to work when I can't even ping the modem?
|
|
|
|
08-25-2004, 09:28 AM
|
#4
|
|
Member
Registered: Oct 2003
Location: /illinois/chicago
Distribution: Slackware/Gentoo/FC/RHEL
Posts: 568
Rep:
|
You need to aquire an IP address (from the modem, not statically assigned).
Once you have an IP, you should be able to ping the modem.
This command will attempt to aquire an IP addy from the modems DHCP daemon.
Once you have the nameserver (also on the modem) as well as a gateway, and an IP, you should have connectivity.
The popular misconception, is that all of these devices run Class C private IP space. This is not always the case.
If you are using some models of SpeedStream modems, as well as some 2Wire products, they use 10.x.x.x space.
Statically assigning IP's to hack your way in might work, but it can be time consuming.
Also, if you would prefer, instead of using the PPP daemon on your box to auth into the DSL network, you can instead program the modem to authenticate for you.
If you don't know how to do this, consult your ISP for help.
DO NOT tell them that you are running Linux - you are asking to be hung up on if you do (My ISP is Comcast, and it's actually against their ToS......lol)
Good luck - we'll be here when you get home if you have further issues....
|
|
|
|
08-26-2004, 11:17 AM
|
#5
|
|
Member
Registered: Jul 2003
Location: London
Distribution: Debian, Redhat
Posts: 98
Original Poster
Rep:
|
Already made that mistake! Phoned BT on their premium rate line (50p every minute) and got on the line to some support techie who started literally ranting at me about how my modem would lead to massive use of bandwidth which would cause some huge bills, or some such stuff which I sounded like bull****! I just wanted to know if the line was clear or had a fault on it.
I actually realised afterwards that I had my modem hooked up to the wrong NIC on my box ... whoops!
Anyway, thanks for the help, I have the modem up and running on the one box. I managed to get the whole dhcp, gateway and nameserver to be done automatically by the modem.
Now what I'm suffering from is the other machines on the internal network. When I try to ping an address on the internet from my other boxes, it says something along the lines of 'network not available'. The other boxes are responding ok. Does this mean my iptables config on the router pc is up the creek, or is it the config on the box where I'm pinging from? (gateway or DNS or something?)
Cheers
|
|
|
|
08-26-2004, 11:21 AM
|
#6
|
|
Member
Registered: Oct 2003
Location: /illinois/chicago
Distribution: Slackware/Gentoo/FC/RHEL
Posts: 568
Rep:
|
The config on the boxes you are pinging from, most likely.
do this:
Learn the syntax (I'm at work, can't check now - hehe) and issue route commands. Set your nameservers in /etc/resolv.conf to be identical to those on the DSL box.
Then, add static route statements into the other boxes that point out the only interface.
When you run route again, you should find a default route.
Now, at the very least, you can ping the DSL box. If you cant ping beyond that, your iptables are probably screwball.
If that's the case, try this first:
Code:
cat echo1 > /proc/sys/net/ipv4/ip_forward
This will enable IP forwarding, which *should* allow your machine to forward from one int to another. Ensure that you are masquarading your IP's for NAT.
Last edited by PenguinPwrdBox; 08-26-2004 at 11:23 AM.
|
|
|
|
08-26-2004, 02:02 PM
|
#7
|
|
Member
Registered: Jul 2003
Location: London
Distribution: Debian, Redhat
Posts: 98
Original Poster
Rep:
|
OK, thanks. I'll try that. I think I can handle route. I remember there was also something fishy about the old network address that popped up at some point. I used to have it (in Germany) on 10.0.0.0 but now here in London I decided it would be easier to configure the modem by using 192.168.1.0, so I changed the network cards's static ips.
|
|
|
|
08-26-2004, 05:23 PM
|
#8
|
|
Member
Registered: Jul 2003
Location: London
Distribution: Debian, Redhat
Posts: 98
Original Poster
Rep:
|
Yo! It worked. For some reason redhat 9 includes network config files not just in /etc/sysconfig/networking/devices but also in /etc/sysconfig/networking/profiles/default. It was using the latter config files, while my router with the modem just uses the normal former. Confused I was.
Then 'route' took care of the rest.
Ta mucho again
|
|
|
|
| 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 08:52 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
|
|