banjo Posted October 5, 2004 Report Share Posted October 5, 2004 Hello, This is a very basic question, but I have not been able to dig the information out of all the details that I am finding in the HOWTO's and other docs. I guess it is just so obvious that it isn't written down anywhere. But I can't figure it out. I must still be a noob. Here is my situation: My Mandy 9.1 currently uses dialup. It works fine. If I try to access the net without a connection it says that the net is not accessible, which is also fine because the net is truly not available. Once I dial up, everything is found OK. All is well. I grok. However..... I plan on moving to broadband soon through a router (the hardware isn't set up yet) which means that all my net traffic will have to go through eth0 instead of through the modem. That is fine too, but..... How does Linux know not to look at the modem for the net access? How does it know to look at eth0 for the net? Will I have to manually configure the system to switch it to the ethernet? If so, where is that information stored? Right now it just somehow knows to look at the modem, but I have no idea how. For example, my DNS servers are configured in the dialup. That is fine while I am using dialup. But if I switch over to ethernet, where do the DNS addresses come from? All the information I have found about the route tables etc. assume that it has an IP address? I need a DNS to get the first IP address. Where does the DNS address come from if not from the dialup? Once it has a DNS IP, how does it know to look to eth0 instead of the modem for net access? This question is more of a "How does it work?" question rather than a "Please solve my problem" question. I want to know how this works before I attempt to set it up. Anybody have any pointers to some very high level docs about how all this network stuff hangs tegether in the Linux box? I am interested in the high level flow, not the details of protocols and routing tricks. Thanks in advance Banjo Linux rocks! Quote Link to comment Share on other sites More sharing options...
banjo Posted October 5, 2004 Author Report Share Posted October 5, 2004 I think I just found an answer to one of my own questions. It appears that when going through a hardware router, the ISP DNS addresses are entered into the router during setup. That makes sense. Name resolution is then handled by the router. Now if I can figure out how Linux knows where to look for the network, i.e. eth0 or the dialup connection, I will be on my way to grokking this system better. Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
jgutty Posted October 5, 2004 Report Share Posted October 5, 2004 I think I just found an answer to one of my own questions. It appears that when going through a hardware router, the ISP DNS addresses are entered into the router during setup. That makes sense. Name resolution is then handled by the router. Now if I can figure out how Linux knows where to look for the network, i.e. eth0 or the dialup connection, I will be on my way to grokking this system better. Banjo (_)=='=~ <{POST_SNAPBACK}> I do not have 10.0, but it should have no problem using the ethernet connection. Using the network portion of drake config (configure your computer in the 9.2 menu), you can configure the eth0 connection Quote Link to comment Share on other sites More sharing options...
banjo Posted October 6, 2004 Author Report Share Posted October 6, 2004 Thanks for the tip. I will look into it. I don't have the hardware yet. I am studying the issues before I actually go in and mess it all up LOL. Looks like they have a Windowesque wizard. But I always wonder what the wizards are doing to my system..... Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
banjo Posted October 6, 2004 Author Report Share Posted October 6, 2004 I made some more discoveries about what my Linux system is doing for networking. and I thought that I would post them here in case anybody else is wondering about these questions. I dialed up my ISP and logged on. Then I did a route command to see what my routing table looks like. Here is the output: [root@localhost proc]# route -n Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 208.200.159.28 0.0.0.0 255.255.255.255 UH 0 0 0 ppp0 127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo 0.0.0.0 208.200.159.28 0.0.0.0 UG 0 0 0 ppp0 [root@localhost proc]# Then, I hung up the phone and executed the route command again and got: [root@localhost proc]# route -n Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo [root@localhost proc]# Nothing left but the loopback. So, I guess the system knows where to go for internet through the routing table (makes sense) and some nice daemon somewhere has changed it based on my connection to the ISP. But here is a more confusing result...... I also dumped out the /etc/resolv.conf file in those two situations, and here is what I got. While online: [root@localhost proc]# cat /etc/resolv.confdomain localdomain #kppp temp entry nameserver 207.77.56.2 #kppp temp entry nameserver 207.77.56.10 #kppp temp entry [root@localhost proc]# and after hanging up: [root@localhost proc]# cat /etc/resolv.conf[root@localhost proc]# That explains where the system is getting the DNS addresses. Something is changing the system setup files automatically. Is that the way resolv.conf is supposed to work? Shades of fnWindoze! What is it that changes the resolv.conf file on the fly? I looked for routed: [root@localhost proc]# ps ax | grep routed and got nothing but the grep command, so it looks like routed is not running...? Anyway, it looks like the internet locations just happen automatically by updating the routing tables. So I am assuming that once I hook up a valid eth0 to a hardware router running DHCP the routing tables will be fixed up to send the TCP/IP requests out to the proper place...... unless I confuse it by trying to use the dialup at the same time.... :D We shall see. But I would still like to know what is keeping the information updated. Any gurus out there? If I find out any more info I will post it 'cause I'm having fun. Linux rocks! Banjo (_)=='=~ [formatted by spinynorman] Quote Link to comment Share on other sites More sharing options...
Gowator Posted October 6, 2004 Report Share Posted October 6, 2004 no need to be a guru.... you answrered your own question ... its the dhcp client that updates when it receives an IP it also gets a default route exported from the router. (also the DNS) However... kudos for working all this out yourself... and yep that is why linux rocks, becuase you can! Quote Link to comment Share on other sites More sharing options...
banjo Posted October 6, 2004 Author Report Share Posted October 6, 2004 Having this board certainly helps discover the answers. I also found some answers at this link: www.linux-mag.com/2001-05/routing_01.html which discusses how Linux routers operate. So I guess that for the dialup the ISP DHCP server is sending the info. When I finally hook up my lan the router DHCP server will do the same. Linux is so kewl. Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
banjo Posted November 8, 2004 Author Report Share Posted November 8, 2004 I thought that I would post a final followup on this topic even though it has been dormant a while. I finally got my DSL connection going today, and my Mandy 9.1 came up runnin'. I had to use my fnWindoze computer to install the DSL service because that is the only thing that will run Verizon's setup program. But once I had the service started, all I had to do for the Linux box was to plug the computer into the modem/router and boot it, and it came up online. Now I need to go research some firewall software. Any suggestions? Linux rocks! Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
Qchem Posted November 8, 2004 Report Share Posted November 8, 2004 Theres probably a firewall built into your router - that should take care of most your firewall needs. Otherwise a good place to start is shorewall. Quote Link to comment Share on other sites More sharing options...
banjo Posted November 8, 2004 Author Report Share Posted November 8, 2004 There is, indeed a firewall in the router. Unfortunately, it is blocking access to the email accounts at my hosting service unless I set it at the lowest level of security. It is enabled (it was disabled by default), but at the lowest level, which is defined as: The Low security setting will allow all traffic except for known attacks. With Lowsecurity, VersaLink is visible to other computers on the Internet. I don't know enough about firewalls yet to figure out what is being blocked or how to get around it, so I am hitting the books. Thanks for the pointer to shorewall, I will read up on it. Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.