免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1966 | 回复: 4
打印 上一主题 下一主题

[网络配置] dig命令的一个菜鸟问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2013-02-22 17:03 |只看该作者 |倒序浏览
我用的是centos6.3,在学习dig命令,
[root@localhost etc]# dig @server baidu.com
dig: couldn't get address for 'server': not found
请问,出现这种情况的原因是什么呢?

论坛徽章:
33
ChinaUnix元老
日期:2015-02-02 08:55:39CU十四周年纪念徽章
日期:2019-08-20 08:30:3720周年集字徽章-周	
日期:2020-10-28 14:13:3020周年集字徽章-20	
日期:2020-10-28 14:04:3019周年集字徽章-CU
日期:2019-09-08 23:26:2519周年集字徽章-19
日期:2019-08-27 13:31:262016科比退役纪念章
日期:2022-04-24 14:33:24
2 [报告]
发表于 2013-02-22 17:16 |只看该作者
       server
           is the name or IP address of the name server to query. This can be an IPv4 address in dotted-decimal notation or an IPv6 address in colon-delimited notation. When the
           supplied server argument is a hostname, dig resolves that name before querying that name server. If no server argument is provided, dig consults /etc/resolv.conf and
           queries the name servers listed there. The reply from the name server that responds is displayed.

这里的server是你指定的name server,一般不需要的。直接:
  1. dig www.baidu.com
复制代码

论坛徽章:
0
3 [报告]
发表于 2013-02-22 17:27 |只看该作者
@server是你指定的dnsserver的ip,如:dig @8.8.8.8 www.baidu.com

论坛徽章:
21
白羊座
日期:2013-08-23 15:49:17金牛座
日期:2013-10-08 17:00:03处女座
日期:2013-10-12 11:54:11CU十二周年纪念徽章
日期:2013-10-24 15:41:34午马
日期:2013-11-27 14:07:21巨蟹座
日期:2013-12-04 10:56:03水瓶座
日期:2013-12-04 15:58:00亥猪
日期:2014-05-24 16:02:3115-16赛季CBA联赛之辽宁
日期:2016-11-07 13:52:53戌狗
日期:2013-08-23 16:15:31白羊座
日期:2013-08-24 21:59:24巨蟹座
日期:2013-08-25 16:34:24
4 [报告]
发表于 2013-02-22 17:33 |只看该作者
直接用dig 域名   就可以了。

论坛徽章:
0
5 [报告]
发表于 2013-02-25 11:34 |只看该作者
回复 3# xingchuang_cu


   你说的对,谢谢你啦
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP