How to clear the DNS cache in Windows

In the Windows DNS cache, records of domain names with their IP addresses to which were accessed are stored. When a user opens a site for the first time, a DNS server is accessed; upon subsequent openings of a site, Windows already takes information from the cache. Therefore, if a new IP address has been assigned to a domain, then the system will access the old one for a while based on the data in the cache.

Continue reading “How to clear the DNS cache in Windows”

How to convert a list of IP addresses to DNS names

In Linux, you can convert a list of IP addresses into DNS names, for example, by a simple script.

To do this, create an empty file with the extension .sh, make it executable and add the content to it:

#!/bin/sh
while read ip traf ; do
    name=`host $ip|awk '{print $NF}'`
    echo -e "$name\t$ip\t$traf"
done >name_ip_traf.lst <ip_traf.lst

Where ip_traf.lst is a file with a list of IP addresses that need to be converted to DNS names.

You can make it executable by the command:

chmod +rwx file.sh

Run the script in the directory where it is located by the command:

./file.sh

Or run by specifying the full path:

/dir/file.sh

After the startup, you must wait for a while or interrupt the execution by pressing CTRL+C.