timeout:n

  sets  the  amount  of time the resolver will wait for a response from a remote name server before retrying the query via a different name server.  Measured in seconds, the default is RES_TIMEOUT (currently 5, see <resolv.h>).  The value for this option is  silently capped to 30.

attempts:n

  sets  the  number of times the resolver will send a query to its name servers before giving up and returning an error to the calling application.  The default is RES_DFLRETRY (currently 2, see <resolv.h>).  The value for this option is silently capped to 5.

rotate

  sets RES_ROTATE in _res.options, which causes round robin selection of nameservers from among those listed.  This has the effect  of  spreading the query load among all listed servers, rather than having all clients try the first listed server first every time.

rotate是伪随机,经常会固定使用某个nameserver,不一定是第一个

Root Cause

The reason why RES_ROTATE related code picks up the second nameserver every time as the first one is that the item rotation of nameserver list happens before contacting any of the nameservers, thus the second nameserver goes as first every time.

https://access.redhat.com/solutions/1426263

/etc/resolv.conf options rotate的更多相关文章

  1. Linux上DNS解析总是选择resolv.conf中第二位的DNS服务器IP地址

    问题现象: 在Linux机器上,用户自建了一台DNS服务器.然后改动/etc/resolv.conf将其服务器IP地址添加到第一项.将阿里云的内网DNS放到第二位,然而在测试过程中发现telnet,p ...

  2. DNS解析超时排查/etc/resolv.conf single-request-reopen参数说明

    添加 options rotate timeout:1 attempts:3 single-request-reopen 添加到/etc/resolv.conf 中 #释义: 循环查询 超时时间 重试 ...

  3. /etc/resolv.conf overwritten. Redhat/Centos

    Prevent /etc/resolv.conf from being blown away by RHEL/CentOS after customizing If you are using RHE ...

  4. docker中执行sed: can't move '/etc/resolv.conf73UqmG' to '/etc/resolv.conf': Device or resource busy错误的处理原因及方式

    错误现象 在docker容器中想要修改/etc/resolv.conf中的namesever,使用sed命令进行执行时遇到错误: / # sed -i 's/192.168.1.1/192.168.1 ...

  5. 优化 resolv.conf

    DNS lookup 在把域名解析成 IP 过程中耽误了不少时间,尤其是访问比较复杂的网站的时候,比如某个页面包含多个 url,一次请求需要做多次 DNS 解析,并且从用户浏览器到 DNS serve ...

  6. 两个坑-Linux下Network-Manager有线未托管-DNS resolv.conf文件开机被清空

    Linux里面有两套管理网络连接的方案: 1./etc/network/interfaces(/etc/init.d/networking) 2.Network-Manager 两套方案是冲突的,不能 ...

  7. CentOS6.3 重启后/etc/resolv.conf 被还原解决办法(转)

    今天一台服务器上不了网,设置了nameserver,重启后/etc/resolv.conf文件就被自动还原了,最后发现是被Network Manager修改了.解决方法:停止Network Manag ...

  8. 转 -- Linux系列:Ubuntu虚拟机设置固定IP上网(配置IP、网关、DNS、防止resolv.conf被重写)

    原文转自:http://www.cnblogs.com/lanxuezaipiao/p/3613497.html#undefined 虚拟机里设置上网方式为NAT最方便,因为无需手动设置即可上网,但是 ...

  9. Linux下/etc/resolv.conf 配置DNS客户

    文件/etc/resolv.conf配置DNS客户,它包含了主机的域名搜索顺序和DNS服务器的地址,每一行应包含一个关键字和一个或多个的由空格隔开的参数.下面是一个例子文件: search mydom ...

随机推荐

  1. js之预解析

    一.所谓的预解析就是:在当前作用域中,JavaScript代码执行之前,浏览器首先会默认的把所有带var和function声明的变量进行提前的声明或者定义. 1)var声明的变量在预解析的时候只是提前 ...

  2. Vue – 基础学习(3):$forceUpdate()和$nextTick()的区别

    Vue – 基础学习(3):$forceUpdate()和$nextTick()的区别

  3. CSS3 新增文本样式

    CSS3 对原来的 CSS2 版本中已定义的属性取值进行修补,增加了更多的属性值,来适应复杂环境中文本的呈现. 一.定义文本阴影 可以给文字添加阴影效果了 Shadow 影子 语法: text-sha ...

  4. FreePascal - CodeTyphon 和 Lazarus, 如何像Delphi一样有代码之间的连线?

    CodeTyphon 6.9 默认CodeTyphon没有开启代码之间连线功能,一直不知道如何调出来,在使用CodeTyphon 和 Lazarus 很渴望也能像Delphi那样有这种功能,实际上它们 ...

  5. ISO模型学习

    PDU:协议数据单元是指层次之间传递的数据单位 物理层PDU :PDU是数据位 bit数据链路层的PDU是数据帧frame网络层的PUD是数据包 packet传输层的PDU是数据段 segment其他 ...

  6. rf中setup与teardown

    setup:是测试一个用例(或者套件)前要做的事情 teardown:是测试后要做的事情 在RF中,每个测试套件目录.测试套件文件.测试用例 都可以有自己的setup 和teardown 所有的 se ...

  7. 【转】在Keil uv5里面添加STC元器件库,不影响其他元件

    先到网上下载stc.CBD(http://download.csdn.net/detail/mao0514/9699117) 还有STC新系列单片机的头文件,宏晶的网站就有 1.在Keil/C51/I ...

  8. linux 使用ssh-keygen生成ssh公钥和私钥

    linux一般为在自己的家目录下建立 .ssh 文件夹 中生成密钥 /home/username/.ssh 生成的命令如下: ssh-keygen -t rsa -C "yourname@y ...

  9. Cobbler--自动化部署

    Cobbler自动化部署 cobbler简介 Cobbler 可以用来快速建立 Linux 网络安装环境,它已将Linux网络安装的技术门槛,从大专以上文化水平,成功降低到了初中水平,连补鞋匠都能学会 ...

  10. Django如何与JQuery进行数据通信?

    index.html: 下面form的action属性表示当提交表单时,向何处发送表单数据 <script src="https://code.jquery.com/jquery-3. ...