Flushing your DNS cache can help to resolve issues with web pages not loading properly or showing outdated information. Here are the steps to flush your DNS cache on a few popular operating systems:
Windows:
- Open Command Prompt as an administrator.
- Type βipconfig /flushdnsβ and press Enter.
- You will see a message that says βWindows IP configuration successfully flushed the DNS Resolver Cache.β
MacOS:
- Open Terminal.
- Type βsudo killall -HUP mDNSResponderβ and press Enter.
- You will be prompted to enter your admin password.
- Once you enter your password, the DNS cache will be flushed.
Linux:
- Open Terminal.
- Type βsudo /etc/init.d/nscd restartβ and press Enter.
- You will be prompted to enter your admin password.
- Once you enter your password, the DNS cache will be flushed.
Ubuntu:
- Open a terminal window by pressing βCtrl+Alt+Tβ
- Type the following command βsudo systemd-resolve βflush-cachesβ and press enter
- You will be prompted to enter your admin password.
- Once you enter your password, the DNS cache will be flushed.
Alternatively, you can use the following command to flush the DNS cache:
- Open a terminal window by pressing βCtrl+Alt+Tβ
- Type the following command βsudo /etc/init.d/dns-clean restartβ and press enter
- You will be prompted to enter your admin password.
- Once you enter your password, the DNS cache will be flushed.
Please note that flushing your DNS cache may cause a temporary interruption in your internet connectivity. Also, itβs important to mention that these steps are for Ubuntu specifically, other Linux distros may have different commands to flush the DNS cache.