Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top
  • In which oder are the nameservers stated in resolv.conf used for name resolution?
  • Is there a way to influence this order?
  • Is this behavior distribution dependent? (I'm using Debian Squeeze)
share|improve this question
up vote 2 down vote accepted

You have a few options on Linux systems...

By default, the nameservers are used in listed order with a 5-second timeout before moving to the next entry.

  • In addition, you can set the options rotate parameter to query the DNS servers in a round-robin manner.
  • You can also lower the default timeout of 5 seconds to 1 second using options timeout:1.

Also see:

share|improve this answer

According to recolv.conf man page, they are used in the order listed in the file.

To change the order they are being used, change the order listed in your resolv.conf.

It is NOT distribution dependent.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.