Ubuntu 13.10 no internet

Little Girl littlergirl at gmail.com
Sun Dec 1 14:37:17 UTC 2013


Hey there,

Errol Sapir wrote:

> You will have to put in your info instead of the numbers I have. If
> your system is DHCP the network setup is:
> 
> auto lo
> iface lo inet loopback
> 
> auto eth0
> iface eth0 inet dhcp
> 
> I don't know what one writes for the dns servers for DHCP but would 
> guess that it is:
> 
> dns-nameservers DHCP
> (but I could be wrong).

Ever since Kubuntu 12.04 the dns-nameservers line is required in
the /etc/network/interfaces file. Without it you will not have
internet service. That's a change from previous releases, which
didn't need it. I have *no* idea why that change was made, but I'm
sure glad we realized it or I wouldn't be able to write to you. (:

You can use the gateway address for dns-nameservers. Here are two
ways to get your gateway information (either one will work) with
explanations of how each does its thing:

netstat -r | awk '/default/ {print $2}'

Explanation:
The netstat command uses the -r option to get the kernel routing table and provides that as output to the awk command, which finds the line that begins with default and prints (displays) the contents of the 2nd column, which is your gateway.

netstat -r | grep 'default' | awk '{ print $2}'

Explanation:
The netstat command uses the -r option to get the kernel routing table and provide that as output to the grep command, which searches for default and finds 6 columns of information. It then passes its findings to the awk command, which prints (displays) the contents of the 2nd column, which is your gateway.

Someone also once recommended 8.8.8.8 as the address for
dns-nameservers. It's Google's public DNS:

https://developers.google.com/speed/public-dns/

I wouldn't do that on a home computer (somehow I feel more secure
with my internet provider's DNS), but I suppose it could be useful in
a school or store or on a demonstration machine. (:

-- 
Little Girl

There is no spoon.




More information about the kubuntu-users mailing list