Click to See Complete Forum and Search --> : Changing routing tables and DNS settings
I have absolutley no idea about Linux... I'm not proud... I just want some answers.
I have an antiquated Linux box acting as a web cache and DNS box. Something about SQUID???
We are changing our ISP and we need to add or change the routing table ( I think). The Box sits within our DMZ. All traffic in bound and outbound passes through this box.
What comands do I enter to see the current settings and how do I change them ?
Can anyone help ?
FCW
Radar
07-08-2002, 04:41 PM
/etc/resolv.conf should have your DNS entries
route -n should show your routing.
# man route will tell you how to use it if you end up needing to change stuff.
Luigi
07-08-2002, 06:28 PM
i just wrote you a little novel about how dns works etc, but my login cookie timed out so i lost it. $@*%$#^!! so sorry, instead of learning about the intricacies of dns servers, here's the condensed version.
your server box uses one of three setups:
1) it relays EVERYTHING to your external ISP. DNS requests go straight through, it's like your linux box isn't even there.
2) it acts as a DNS server for your private network... a more secure method.
3) anything else ;)
CASE 1)
your linux box is acting like a filter, keeping out unwanted traffic. it is otherwise transparent... so your client system is getting it's internet address and information directly from your ISP. in this case, all you need is to make sure your linux box is configured for your new ISP. run
/etc/init.d/network stop
and watch your internet shut down. then run
/etc/init.d/network start
and watch it come up again. try and access the internet by running
ping www.yahoo.com
(press Ctrl+C to stop) if you get any responses, you should be good to go on your local network. otherwise, run
netconfig
it will walk you through your internet settings. they will either be assigned dynamically (DHCP), or readily available from your ISP. if you still have trouble with the 'net from your client machines, follow the steps that Radar set out... your firewall/routing table is doing something funny.
CASE 2)
you should actually be fine, so long as your linux box is configured to access the 'net. your DNS server will still query the same central 'root' servers, no matter what ISP you're on... so follow the steps above to make sure your access is set up right. your firewall should not need reconfiguration.
CASE 3)
you mentioned SQUID. I don't personally use it, but here is what I know. SQUID is a caching proxy server. this means that when your client computer asks for a webpage, it sends the request to the SQUID server. SQUID then looks up the webpage, and downloads it. it keeps a copy, and sends the other copy to your client machine. from now on, whenever any other client requests that page, SQUID will serve it the copy it saved (called it's cached copy). most proxy servers handle DNS for you, but not all of them. you'll have to use SQUID's internal configuration (which I don't know anything about). good luck on this one ;)
Luigi
07-09-2002, 12:31 PM
in response to your private message....
hmmmm... i've only heard the term 'routing table' used in reference to those automated linksys routers, so let me know if i'm using the wrong terminology here :) ....
the routing table (to my understanding) is how the server identifies packets that are destined for a particular client on the inside. the most common linux utilities to manage these tables combine them with firewall rules. it doesn't make conceptual sense, but the rules are similar. it might look like this (in english). lines preceded by a # are comments.
allow all outgoing connections from clients.
if incoming data is a part of an existing connection, forward it to the connecting client.
#let's say that client computer client4 is running an ftp server.
# we want to automatically send traffic on the ftp port to client4
if incoming packet is on port 21, forward it to client4 port 21
deny all other connections.
this way, you're allowing connections that clients request, forwarding a particular port (or type of data, if your table can support that kind of filter) to a particular machine, and denying any incoming connections. this is my idea of a routing table... and it shouldn't change with your isp! the only thing it relies on is your internet connection.
what SHOULD change however are your ethernet settings. to change your network settings, you want to login as root and type netconfig . you can set ip, dns, gateway, wins, anything.... or just set it all to dhcp, if you like.
hope this helps, let me know if there's anything else i can do for you.