To refresh the DNS cache in Linux Mint 20, you can use the following steps:
-
Open the Terminal: You can do this by pressing the
Ctrl+Alt+T
keys together, or by searching for “Terminal” in the Applications menu. -
Clear the DNS cache: Use the following command to clear the DNS cache:
sudo systemd-resolve --flush-caches
This will flush both the positive and negative DNS caches.
-
Verify the cache is cleared: You can verify that the DNS cache has been cleared by using the following command:
systemd-resolve --statistics
This will display the statistics of the DNS cache, including the number of queries and the cache size.
If the cache size is 0, then the DNS cache has been successfully cleared.
That’s it! Your DNS cache should now be refreshed.