Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DNS won't resolver through router/proxy

Status
Not open for further replies.

niknight

Technical User
Jan 16, 2003
2
GB
I have RedHat8 running on a small LAN. My proxy/router has DNS and NAT enabled and is working fine. I can ping internet addresses by IP, but not by name. I have at times managed to get the RH8 box to use the proxy's DNS for name resolving but it is lost after reboot.
Here's the setup:

Router/proxy server:
IP: 10.0.0.1
Subnet: 255.255.255.0

RH8 box:
IP: 10.0.0.140
subnet: 255.255.255.0

Contents of /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
USERCTL=yes
PEERDNS=yes
TYPE=Ethernet
IPADDR=10.0.0.140
NETMASK=255.255.255.0
GATEWAY=10.0.0.1
NETWORK=10.0.0.0
BROADCAST=10.0.0.255

Contents of /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=localhost.localdomain
GATEWAY=10.0.0.1

Contents of /etc/resolv.conf
; generated by /sbin/dhclient-script
search 10.0.0.1
nameserver 10.0.0.1

Contents of /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.

127.0.0.1 localhost.localdomain localhost
10.0.0.140 mypc mypc.localdomain
10.0.0.1 ntbox ntbox.localdomain

Any ideas anybody. This is slowly killing me. Aarrrghhh! ;)
 
You need to specify your ISPs DNS server in /etc/resolv.conf.

nameserver dns1
nameserver dns2

etc. It will enable your RH box to resolve names. Then you can install DNS server for your internal network. Install 'bind' package, then 'caching-nameserver'. Change dns for your nt box to rh box. And if it won't work, let us know.
 
Yup, I've done that now. What really had me confused is that on a few occasions, the NT box WAS resolving domain names and it still does for the Win98SE box on my LAN.

Still, it's working perfectly now, so I guess I'll leave well enough alone.

Thanks anyway.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top