DNS not working after Precise 11.10 -> 12.04 Mythbuntu upgrade

Asked by danstowell

Hi - upgraded Mythbuntu 11.10 to 12.04, and I can't get DNS resolution to work, so I can't access any web. I upgraded using the normal GUI program.

My local network works ("ping 192.168.254.13" successfully pings my other machine); I can ssh to the machine from outside; I can ping IP addresses outside the network.

I don't have any weird network setup as far as I know, and I don't want anything weird - just a single wired connection.

Here are some file contents and diagnostics:

I don't have a file /run/nm-dns-dnsmasq.conf

Here's /etc/network/interfaces :
=======================================================
auto lo
iface lo inet loopback

#auto eth0
#iface eth0 inet static
# address 192.168.254.202
# netmask 255.255.255.0
# network 192.168.254.0
# broadcast 192.168.254.255
# gateway 192.168.254.254

auto eth1
iface eth1 inet static
        address 192.168.254.1
        netmask 255.255.255.0
        network 192.168.254.0
        broadcast 192.168.254.255
        gateway 192.168.254.254

=======================================================

$ ifconfig
eth1 Link encap:Ethernet HWaddr aa:00:04:00:0a:04
          inet addr:192.168.254.1 Bcast:192.168.254.255 Mask:255.255.255.0
          inet6 addr: fe80::a800:4ff:fe00:a04/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:579 errors:0 dropped:0 overruns:0 frame:0
          TX packets:519 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:114187 (114.1 KB) TX bytes:66795 (66.7 KB)
          Interrupt:17

lo Link encap:Local Loopback
          inet addr:127.0.0.1 Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING MTU:16436 Metric:1
          RX packets:313 errors:0 dropped:0 overruns:0 frame:0
          TX packets:313 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:29500 (29.5 KB) TX bytes:29500 (29.5 KB)

virbr0 Link encap:Ethernet HWaddr de:c5:2b:8d:a7:e2
          inet addr:192.168.122.1 Bcast:192.168.122.255 Mask:255.255.255.0
          UP BROADCAST MULTICAST MTU:1500 Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)

$ nm-tool

NetworkManager Tool

State: disconnected

- Device: eth1 -----------------------------------------------------------------
  Type: Wired
  Driver: sky2
  State: disconnected
  Default: no
  HW Address: AA:00:04:00:0A:04

  Capabilities:
    Carrier Detect: yes
    Speed: 100 Mb/s

  Wired Properties
    Carrier: on

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu network-manager Edit question
Assignee:
No assignee Edit question
Solved by:
Jacob Mansfield
Solved:
Last query:
Last reply:
Revision history for this message
danstowell (danstowell) said :
#1

Here are .tgz of my /etc/resolvconf and /run/resolvconf:

http://mcld.co.uk/tmp/etc-resolvconf.tar.gz

http://mcld.co.uk/tmp/run-resolvconf.tar.gz

Revision history for this message
Jacob Mansfield (cyberjacob) said :
#2

Could you post the results of the command
cat /etc/resolv.conf

Revision history for this message
danstowell (danstowell) said :
#3

$ cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN

Revision history for this message
Jacob Mansfield (cyberjacob) said :
#4

There's your problem, no DNS servers.
Are you using network manager to configure your interfaces?

Revision history for this message
Best Jacob Mansfield (cyberjacob) said :
#5

Silly question, the program output you provided in the original question answered it.
A fix would be to add a line similar to the following to the eth0 section of your /etc/network/interfaces

dns-nameservers 8.8.8.8 8.8.4.4

Which would add the Google public DNS servers to your DNS server list.
You may have to restart networking (if-down eth0 then if-up eth0) after adding this change.

Revision history for this message
danstowell (danstowell) said :
#6

Yes.

Not sure if this helps but here's the content of the file which seems to relate to my connection /etc/NetworkManager/system-connections/Wired\ connection\ 1
(I've censored a couple of items)

[802-3-ethernet]
duplex=full
mac-address=[[censored]]

[connection]
id=Wired connection 1
uuid=[[censored]]
type=802-3-ethernet
timestamp=1339107348

[ipv6]
method=ignore

[ipv4]
method=manual
dns=8.8.8.8;8.8.4.4;
addresses1=192.168.254.1;24;192.168.254.254;
may-fail=false

Revision history for this message
danstowell (danstowell) said :
#7

Thanks Jacob Mansfield, that solved my question.

Revision history for this message
danstowell (danstowell) said :
#8

One thing I don't understand is why NM would have a dialogue entry for DNS servers when it doesn't actually cause the system to use them.

Revision history for this message
steve soutar (y9a7s7tjd2jxyck2jcx-steve) said :
#9

I have just UPGRADED from 11.10 to 12.04 LTS & I have seen exactly the same behaviour - I put the 12.04 Live CD on a usb stick, & was given (among other options) fresh installation of 12.04, or the option to "upgrade, preserving existing files" (if I remember what the prompt said correctly)

naturally I chose to preserve my existing environment & upgraded. Had several problems getting back into my own workstation, & one of them is this 'new' DNS mechanism which overwrites the contents of /etc/resolv.conf at every reboot

## This behaviour is not mentioned in the release notes as far as I can see !!
===========================================================

according to various notes I've read, the upgrade was _supposed_ to preserve my existing resolv.conf entries - but it doesn't.

I have booted using dhcp, network manager gets the addresses for my office DNS servers but it is NOT passed through to resolv.conf.

I have had to google, & manually added the following lines to resolvconf/resolv.conf.d/tail

dns-nameservers 192.168.102.1 86.234.136.136
dns-search futureservers.net

I now have address resolution, but where yesterday I could ping, ftp or ssh to 'dave' I now have to specify 'dave.fulldomain.net' - haven't got the patience to debug everything yet as I've got work to do ... I think need to add a dns-domain string as well

love the ubuntu platform - but I think the release testing for upgrades needs some work guys

I often recommend ubuntu to my friends who still use Windoze - things like this are VERY likely to chase new users away again