Questions tagged [resolv.conf]

/etc/resolv.conf contains Domain Name System(DNS) related configuration information on Unix systems.

146 questions
8
votes
2 answers

What is the difference between search domains and nameservers?

I've usually seen two kinds of entries in /etc/resolv.conf on certain servers. The domain-name-servers entry specifies which DNS to use for resolving hostnames to IP addresses. Recently I saw an entry for search IP_ADDRESS. So here's my question.…
8
votes
4 answers

Why must a linux server be rebooted to properly handle a change in resolv.conf?

I know this has to just be a lack of my understanding but here's the problem. We recently changed DNS servers from 192.168.1.1 to .2, so I went around to all 8 of my linux servers and changed /etc/resolv.conf to reflect the change. Note that…
Gray
  • 244
  • 3
  • 8
8
votes
2 answers

Search and Domain in resolv.conf = slow lookups on Ubuntu

I have a machine running ubuntu 10.04 server. I've started getting long (5-10 second) delays when making connections to (some) sites outside of the LAN using tools like curl and wget. Using tcpdump and wireshark, I've found the problem to be in the…
MikeL
  • 183
  • 1
  • 4
7
votes
4 answers

How to set a per-user resolv.conf

Is there a way to specify a per-user resolv.conf? What I found are vague references to the possibility of having a per-user host file, but I'm not interested in that, I'm actually interested in a full resolv.conf, because I want to set different…
miniBill
  • 248
  • 2
  • 12
7
votes
3 answers

Number of nameserver entries in resolv.conf

How many nameserver entries can I give in /etc/resolv.conf? I have given our ISP's 2 nameserver entries as first and second. But since they have issues sometimes, I would like to add Google public nameserver enry. Does a 3rd & 4th entry make any…
nitins
  • 2,579
  • 15
  • 44
  • 68
6
votes
4 answers

Ubuntu 12.04 host lookups extremely slow

I'm having issues with one of my servers taking a long time to look up host names. This is an Ubuntu 12.04 box, so I've tried following the new resolvconf directives. In my /etc/network/interfaces file, I defined my name servers like this: auto…
nwalke
  • 643
  • 2
  • 12
  • 32
5
votes
3 answers

In resolv.conf, why do my search domains have a period after them?

What's the difference between server.com and server.com. in the search section of an /etc/resolv.conf file? user@host /etc/sysconfig/network-scripts $ head -n 3 /etc/resolv.conf # Generated by NetworkManager domain sub.company.com search…
CHK
  • 266
  • 2
  • 7
5
votes
1 answer

DNS server can't resolve localhost name

I'm trying to set up an Apache server on my RHEL6.4 vm and can't because dnsmasq can't recognize the hostname for some reason: nslookup rhel64.example.com Server: xxx.xxx.xx.1 Address: xxx.xxx.xx.1#53 server can't find…
pt18cher
  • 153
  • 1
  • 1
  • 4
5
votes
2 answers

Linux keeps retrying failed DNS server

Whenever one of the servers in /etc/resolv.conf is unreachable, Linux/glibc/whatever isn't smart enough not to retry it for a while. This results in a lot of services becoming unavailable, because a lot of them do reverse lookups on all incoming…
Halfgaar
  • 8,084
  • 6
  • 45
  • 86
4
votes
2 answers

Cannot ssh or ping hostname, but dig and nslookup work on Ubuntu 18.04

I updated my kernel this weekend, and now I'm using 5.3.1. christopher@HAL4:~$ uname -r 5.3.1-050301-generic I need to login to servers, but I cannot do so by hostname any longer. For example, I have a server, "web4," and it's local IP is…
DevOpsSauce
  • 348
  • 1
  • 5
  • 22
4
votes
2 answers

Prevent additional DNS queries when "search" is not set

The host in question is running Arch Linux with hostname set to foo.example.org. There is no search directive in /etc/resolv.conf. If I ping example.com or curl example.com or wget example.com (example.com does not exist, NXDOMAIN), there would be…
Zhuoyun Wei
  • 380
  • 2
  • 4
  • 11
4
votes
2 answers

NetworkManager & dnsmasq - ignore auto DNS settings

I'm running Arch Linux with NetworkManager and dnsmasq set up. It all seems to work fine, except that I try to use the new CloudFlare 1.1.1.1 DNS, but the resolver keeps using the DNS that is advertised by my router. The nameservers seem to be…
Taco de Wolff
  • 153
  • 1
  • 1
  • 7
4
votes
3 answers

Sendmail and nslookup resolution problems

On my Ubuntu server I've been trying to get the PHP mail() function to work by installing sendmail (I also have postfix installed but I gave up on it). However, when I try to send mail it gets queued with the following error in…
4
votes
3 answers

Randomize DNS Nameservers

Is it possible to list multiple nameservers in /etc/resolv.conf on a Unix system and resolve dns queries using a random nameserver when making a dns query and not just the first one?
Steve
  • 41
  • 1
  • 2
4
votes
3 answers

Clients didn't switch to secondary DNS server during fail over

I have two internal dns servers set up and all my servers have both of them in the resolv.conf Our main dns server went down and suddenly no server could see each other. I edited a few of the servers resolv.conf manually and committed out the first…
The Digital Ninja
  • 764
  • 4
  • 10
  • 25
1
2
3
9 10