Two cases of dns resolution failure troubleshooting

                      Two cases of Dns resolution failure

   1. A colleague asked about the failure of parsing the domain name in the intranet url, bug.raisecom.com, asked the reason and solution?

   He said that the dns failed to set a fixed ip, and the ip was set to be obtained automatically, but the dns is ok as shown in the figure below?

Tell him that the preferred dns is the internal dns, and the static dns table entry is set on it, which will map the set intranet domain name to the intranet address, but sometimes the pc will choose the public dns address of the backup dns server, resulting in the inability to query dns content, causing the dns query to fail. Let him capture the packet to see if he has gone to the public network dns?

    Specifically, let him execute ipconfig/flushdns under cmd, then ping bug.raisecom.com, and then filter dns contains raisecom || icmp in the packet capture.

    The echo query fails, and it is found that the public network dns is gone.

I don’t know the mechanism for the order in which the PC chooses dns. After asking him to delete the backup dns and keep only the intranet dns, the problem is solved.

2. Another colleague reported that WeChat can be used, but the Internet cannot be accessed, and ping baidu.com is not available, as shown in the figure below:

     Looking at the results, the dns output is an intranet address, how could this be?

look at his settings

    Looking at the internal network 192.168.212.1 set by dns, there is no problem, take a look at the packet.

Use ipconfig/flushdns in cmd to clear the dns cache, ping baidu.com, and then check the corresponding filter item in wireshark dns contains baidu || icmp to see the results of dns and ping?

It is found that the dns uses the ipv6 protocol, and the dns server in the environment returns the ip of baidu.com is 192.168.1.1, which causes the ping to be sent out, and the default route of the gateway is used to go out. There is no reply after timeout, and time out is displayed.

In the environment, there are many people and hands, and it is impossible to check which device it is. Let's observe after turning off the ipv6 protocol.

Feedback, after removing the ivp6 protocol, it works normally.

Summarize:

When PC sets two dns, sometimes it will switch to the second dns to query the address, the specific switching mechanism is not clear.

When the ipv6 gateway is set, the equipment that develops ipv6 below will be reversed to the ipv6 device by changing the dns transmission, resulting in query failure.

Guess you like

Origin blog.csdn.net/wj31932/article/details/114985121