小编dan*_*dan的帖子

无法连接到本地计算机上的 dnsmasq,端口已打开但连接被拒绝

我正在运行 Scientific Linux 6.3,刚刚将计算机更新为 dnsmasq-2.48-13.el6.x86_64。该机器的本地 IP 为 192.168.1.100。我有一个本地缓存 DNS 设置,在更新之前一直有效。

/etc/dnsmasq.conf配置:

strict-order
listen-address=192.168.1.100
bind-interfaces
cache-size=5000
Run Code Online (Sandbox Code Playgroud)

我确认 dnsmasq 正在运行,端口在我启动和停止 dnsmasq 时打开和关闭。

$ netstat -nl # shows that the port was opened
Proto Recv-Q Send-Q Local Address           Foreign Address        State
tcp        0      0 192.168.1.100:53        0.0.0.0:*              LISTEN
udp        0      0 192.168.1.100:53        0.0.0.0:*
Run Code Online (Sandbox Code Playgroud)

但尝试解决失败

$ nslookup google.com 192.168.1.100
;; connection timed out; trying next origin
;; connection timed out; no servers could be reached
Run Code Online (Sandbox Code Playgroud)

即使尝试 telnet 也失败

$ telnet 192.168.1.100 53
Trying 192.168.1.100...
telnet: …
Run Code Online (Sandbox Code Playgroud)

rhel dnsmasq

2
推荐指数
1
解决办法
1万
查看次数

标签 统计

dnsmasq ×1

rhel ×1