Get the App
SLTechnology News&Howtos  ›  Network Security  › 

How to thoroughly repair DNS pollution?

Shulou Source: shulou.com Published: 2022-06-01 04:18:57 10月02日 Update

Usually used on the system, here in the Windows system as an example, the system usually has a DNS cache DNS records. What is the use of caching DNS records? It helps the system locate and access DNS addresses quickly. However, sometimes there may be problems with some DNS records cached, resulting in the inability to open a web page when it is opened. If you encounter this situation, you can try to manually view or clear the DNS records inside these systems with commands.

Moreover, while maintaining the website, you can use iis7 website monitoring to check whether it is polluted by dns and hijacking and other security issues at the first time, and you can detect whether there is a problem with snapshots. Fix DNS as follows:

First, press and hold the "Start +R" key combination on the keyboard, enter "CMD" in the pop-up operation window, and then click the "OK" button

Note: CMD is a command interpreter under Windows system, which can accept input system commands.

The CMD window will then be launched, and one of the commands used here for network operations is "ipconfig." We can type "ipconfig /?" in CMD window. ", press Enter on your keyboard for help with this command

You can then find three command parameters for DNS operations in Command Help

Enter the "ipconfig /displaydns" command format here to view all DNS records currently cached

Then you can see many DNS records flashing in the command window, you can use the mouse to drag the slider bar on the right side of the window to view all records.

To clear the DNS records cached on the current system, type "ipconfig /flushdns" in the command window and press Enter on the keyboard

Then you can see a prompt message in the command window that the current DNS resolver has been successfully refreshed.

Then you can type "ipconfig /displaydns" again to view the current DNS cache records, and you will find that the refreshed DNS cache records are fewer and are the most recent DNS records.

methodology II

In addition to manually repairing some DNS records cached inside the system, but sometimes some other malicious software, viruses may secretly modify the DNS files of the system behind our back. This DNS file is located in the system directory under the system disk. The file name is "hosts". Generally, it is C:\Windows\System32\Drivers\etc

This hosts file is a text file. Double-click with the mouse and select Notepad to open it.

After opening the hosts file, the content is divided into two parts, the first part is the English introduction of this file, and the latter part is the DNS record of the local machine.

If you find any other strange DNS records in this file, you can delete them. But since this directory is a system directory, the system doesn't modify it directly with Notepad. You can copy this hosts file to other directories on your computer, copy it to your desktop first, and then open this file with Notepad to modify and save it.

Then copy the repaired hosts file to the C:\Windows\System32\Drivers\etc directory

Then select Replace files in destination

If prompted to require administrator privileges, click the Continue button to continue

The DNS file in the system directory was repaired.

Tags: System file command cache directory input situation keyboard question help enter key manual button sometimes website notepad mouse prompt selection pollution Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker Microsoft Shulou Tech Info Xiaomi Huawei