A Guide to Clearning DNS Cache on Different Operation Systems

A Guide to Clearning DNS Cache on Different Operation Systems

Cache make websites faster with a simple technique. When users visit a particular website, some of the data gets stored in the browser. So the next time the user loads the website, the stored data gets utilized to load the content faster. Likewise, the operation system also collects data to provide faster browsing experience. The cache comprises of multiple records, including the IP addresses, hostnames, and media files.

But there’s a problem with the use of caching. When you update the DNS server of your domain that’s associated with the website, there are times when it doesn’t work well for the user. He/she will see the same old version of your website. That’s because of old cache files still saved in the local machine. To fix this problem, you’d have to clear the browser cache and also the local OS cache. Without this, the user will keep browsing the old version. In this article, learn how to do this.

For Microsoft OS

The process to flush the cache is OS-specific. So if you’re on Windows, you’re going to follow different steps than Linux users. Let’s begin with Microsoft users. Here are the steps to follow:
  • Open the command prompt with Windows+R and enter cmd
  • Execute this command -
ipconfig /flushdns

  • Once the cache is successfully discarded, you will get a confirmation message
For Linux OS

Linux users should follow the below steps:
  • Open the terminal with Ctrl+Alt+T
  • Execute this command -
sudo /etc/init.d/nscd restart
For Mac OS X

Users on Mac OS X need to follow these steps:

  • Open the terminal

  • Execute this command if you’re a user of Mac OS Sierra, X El Capitan, X Mavericks, X Mountain Lion, or X Lion -
sudo killall -HUP mDNSResponder
  • For users of Mac OS X Snow Leopard, the command to execute is -
sudo dscacheutil -flushcache
  • Users of Mac OS X Yosemite, the command to execute is -
sudo discoveryutil udnsflushcaches
  • Users of Mac OS X Leopard need to execute this command -
sudo lookupd -flushcache
Executing the commands will flush the cache from the OS. Doing so regularly is also important from a security perspective. Hackers use DNS spoofting techniques to get into your OS. Regularly updating the cache will counter these evil techniques.
First release
Last update
0.00 star(s) 0 ratings

More resources from kumkumsharma