I can lookup DNS hostnames with dig and nslookup, but nothing else seems to be able to resolve anything. ping, telnet, Firefox, everything gets “unknown host”. For example:
> dig yahoo.com
; <<>> DiG 9.6.1-P2 <<>> yahoo.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 20438
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 13, ADDITIONAL: 0
;; QUESTION SECTION:
;yahoo.com. IN A
;; ANSWER SECTION:
yahoo.com. 17579 IN A 209.131.36.159
yahoo.com. 17579 IN A 209.191.93.53
yahoo.com. 17579 IN A 69.147.114.224
;; AUTHORITY SECTION:
. 10071 IN NS L.ROOT-SERVERS.NET.
. 10071 IN NS I.ROOT-SERVERS.NET.
. 10071 IN NS H.ROOT-SERVERS.NET.
. 10071 IN NS F.ROOT-SERVERS.NET.
. 10071 IN NS M.ROOT-SERVERS.NET.
. 10071 IN NS B.ROOT-SERVERS.NET.
. 10071 IN NS A.ROOT-SERVERS.NET.
. 10071 IN NS D.ROOT-SERVERS.NET.
. 10071 IN NS G.ROOT-SERVERS.NET.
. 10071 IN NS J.ROOT-SERVERS.NET.
. 10071 IN NS E.ROOT-SERVERS.NET.
. 10071 IN NS C.ROOT-SERVERS.NET.
. 10071 IN NS K.ROOT-SERVERS.NET.
;; Query time: 2 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Fri Jan 8 01:02:38 2010
;; MSG SIZE rcvd: 286
> ping yahoo.com
ping: unknown host yahoo.com
> ping 209.131.36.159
PING 209.131.36.159 (209.131.36.159) 56(84) bytes of data.
64 bytes from 209.131.36.159: icmp_seq=1 ttl=55 time=97.2 ms
64 bytes from 209.131.36.159: icmp_seq=2 ttl=55 time=98.9 ms
I should mention, I’ve tried disabling the firewall and AppArmor but that doesn’t seem to change anything.
This is a multihomed machine with manaully configured IP, and I think when I did the manual config that’s when things went awry. If there are any files/whatever I can provide let me know. I’ve done this before though and I can’t see where I’ve gone wrong. The default gateway is set and the nameservers are set to 127.0.0.1 and my ISP’s servers.
The basic IP functionality seems to work, but the name lookups do not. For example, I can ssh to my work server via IP address but not hostname. And I found the IP address with nslookup on the problem machine.
The problem seems to be with configuring through YaST. I specified my nameservers in YaST under Network Devices, and they show up in /etc/sysconfig/network/config in the NETCONFIG_DNS_STATIC_SERVERS line, but they are not being used. I added them manually to /etc/resolv.conf (despite all the warnings in the stock file not to change it) and name resolution works.
Is there a bug in YaST that prevents it from updating /etc/resolv.conf properly?
On 01/08/2010 10:46 AM, letrout wrote:
>
> The problem seems to be with configuring through YaST. I specified my
> nameservers in YaST under Network Devices, and they show up in
> /etc/sysconfig/network/config in the NETCONFIG_DNS_STATIC_SERVERS line,
> but they are not being used. I added them manually to /etc/resolv.conf
> (despite all the warnings in the stock file not to change it) and name
> resolution works.
>
> Is there a bug in YaST that prevents it from updating /etc/resolv.conf
> properly?
There was a bug that prevented the update because the system thought that the
user had modified the file. AFAIK, that bug is now fixed. Deleting
/etc/resolv.conf was usually enough to fix the problem.
Whatever it is, I don’t think it’s fixed. Today I noticed an install that was working yesterday had non-functioning networking. I decided to just reinstall it. All I did was reinstall (KDE with some additional server and dev packages) and then do an Online Update (and reboot). Everything seemed fine, then I enabled named in the runlevel editor. Everything still seemed ok, but coming back an hour later lookups were broken again. I had saved a copy of the original resolv.conf after install and did a diff to the current one - sure enough, something had removed the nameserver lines.
Although I didn’t see it happen immediately it seems to me that this has something to do with starting named. Why can’t I run named on a machine while using other hosts as resolvers? That doesn’t make sense to me.