Solved

Ubuntu Server Won't Resolve Hostnames

Posted on 2014-02-18
10
1,820 Views
Last Modified: 2014-02-20
Just installed a fresh build of Ubuntu Server 12.04.4 x64 to find that I can't get DNS functionality to work.  In the configuration wizard, I entered the name server of 8.8.8.8.  I can successfully ping this IP and can see its entry in /etc/resolv.conf and /etc/network/interfaces.  But I can't perform nslookup or ping any hostname.
0
Comment
Question by:marrj
  • 3
  • 3
  • 2
  • +2
10 Comments
 
LVL 21

Expert Comment

by:Mazdajai
ID: 39868788
Is iptables running? What is your network configuration?
0
 
LVL 1

Author Comment

by:marrj
ID: 39868799
I'm fairly new to Linux.  How do I tell if iptables is running?

By network configuration, do you mean the content of the /etc/network/interfaces file?
0
 
LVL 48

Expert Comment

by:Tintin
ID: 39868845
What's the output of

iptables -L
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 
LVL 21

Expert Comment

by:Mazdajai
ID: 39869167
Yes. Beside iptables provide the following -

dig google.com 8.8.8.8

Open in new window

0
 
LVL 13

Expert Comment

by:Sandy
ID: 39869615
Also check with your network guy whether port 53 is open or not to allow name resolution.

TY/SA
0
 
LVL 8

Expert Comment

by:Surrano
ID: 39870223
Instead of asking to open port 53 I'd recommend to ask your network team to give you a proper DNS IP within the intranet. Tends to be more friendly and less prone to future nasty comments from network team :)
0
 
LVL 1

Author Comment

by:marrj
ID: 39870284
Output from iptables -L

Chain INPUT (policy ACCEPT)
target     prot opt source     destination

Chain FORWARD (policy ACCEPT)
target     prot opt source     destination

Chain OUTPUT (policy ACCEPT)
target     prot opt source     destination




Output from dig google.com 8.8.8.8

;; global options: +cmd
;; connection timed out; no servers could be reached
;; connection timed out; no servers could be reached



I happen to the be the network guy, and I am certain that outbound TCP53 is open at my ASA.  This server is going to be in a DMZ, and I really don't want to open up anything from the DMZ to the inside that I don't have to.  I've also got a static NAT created at my ASA for this machine.  As I said, I can ping any IP (public or private) that I want to.  I just can't perform name lookups.  I don't think it's a NAT or port issue.  I've got a Windows server set up the same way and have no problems performing nslookup on 8.8.8.8.
0
 
LVL 48

Assisted Solution

by:Tintin
Tintin earned 250 total points
ID: 39871782
Make sure you have UDP 53 opened on the ASA.   Most DNS queries are over UDP rather than TCP.
0
 
LVL 21

Accepted Solution

by:
Mazdajai earned 250 total points
ID: 39872322
>>I've got a Windows server set up the same way and have no problems performing nslookup on 8.8.8.8.

Can you confirm the Ubuntu server and the Windows are in the same subnet? As well as UDP53 is open?
0
 
LVL 1

Author Comment

by:marrj
ID: 39873884
I decided to reinstall the OS from scratch.  Now, DNS works fine.  Strange.  Thanks for your help.
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question