/etc/resolv.conf中关键字search和domain的作用
2014-10-01 12:56
656 查看
domain 声明主机的域名。很多程序用到它,如邮件系统;当为没有域名的主机进行DNS 查询时,也要用到。如果没有域名,主机名将被使用,删除所有在第一个点( . )前面的内容。
search 它的多个参数指明域名查询顺序。当要查询没有域名的主机,主机将在由search 声明的域中分别查找。domain 和search 不能共存;如果同时存在,后面出现的将会被使用。
下面的说明更清晰
在/etc/resolv.conf 配置文件:domain 和search作用是一样的
domain linpro.no
search linpro.no uio.no ifi.uio.no
domain function:
Had I typed telnet math.uio.no. with the trailing dot, the resolver would have known it was an FQDN and would have looked up math.uio.no at once, without trying to append the specified domain
first. Not all applications are tolerant of the trailing dot, though, so it can't always be specified.
search function:
When ssh gram is executed, the resolver first looks for gram.linpro.no, which does not exist; thengram.uio.no, which does not exist, either; and finally gram.ifi.uio.no, which
will succeed because it does exist
search 它的多个参数指明域名查询顺序。当要查询没有域名的主机,主机将在由search 声明的域中分别查找。domain 和search 不能共存;如果同时存在,后面出现的将会被使用。
下面的说明更清晰
在/etc/resolv.conf 配置文件:domain 和search作用是一样的
domain linpro.no
search linpro.no uio.no ifi.uio.no
domain function:
Had I typed telnet math.uio.no. with the trailing dot, the resolver would have known it was an FQDN and would have looked up math.uio.no at once, without trying to append the specified domain
first. Not all applications are tolerant of the trailing dot, though, so it can't always be specified.
search function:
When ssh gram is executed, the resolver first looks for gram.linpro.no, which does not exist; thengram.uio.no, which does not exist, either; and finally gram.ifi.uio.no, which
will succeed because it does exist
相关文章推荐
- /etc/resolv.conf中关键字search和domain的作用
- 解决ubuntu下resolv.conf 丢失domain, search 配置
- 转载:/etc/resolv.conf的作用
- linux下etc下resolv.conf文件的作用
- resolv.conf:search、domain、nameserver解释
- linux下etc下resolv.conf文件的作用
- ubuntu12.04:/etc/resolv.conf isn't a symlink, not doing anything
- linux根文件系统 /etc/resolv.conf 文件详解
- /etc/resolv.conf overwritten. Redhat/Centos
- linux根文件系统 /etc/resolv.conf 文件详解
- Linux 网络配置 修改DNS配置文件/etc/resolv.conf后,重启网络,DNS配置丢失
- 【Linux网络配置】linux中修改/etc/resolv.conf又恢复到原来的状态
- CentOS6.3 重启后/etc/resolv.conf被还原解决办法
- /etc/ld.so.conf.d/目录下文件的作用
- AIX /etc/resolv.conf文件详解
- 域名服务器配置文件 /etc/resolv.conf
- CentOS6重启后/etc/resolv.conf被还原解决办法
- /etc/syslog.conf文件作用
- FreeBSD/Linux 中避免 /etc/resolv.conf 被改写 + 几种解决办法的比较 !
- /etc/ld.so.conf.d/目录下文件的作用