Site Overlay

DNS Cache Clearing

Clearing the DNS Cache:
If you're having trouble accessing a webpage or using an online service, your device may have cached an outdated DNS record that needs to be manually cleared or reset.

Clearing the DNS Cache in Microsoft Windows

The following command will work on Windows 7, 8, 10 + Windows Server, but opening the command prompt is slightly different for each version.

  1. Right-click on the Start menu and select Command Prompt (Admin) from the menu.
  2. Type the following command.
ipconfig /flushdns
DNS Cache Clearing
DNS Cache Clearing in Windows 1
image 69
DNS Cache Clearing in Windows 2

Clearing the DNS Cache in Apple MacOS and Mac OS X

From the Mac application, you need to run the following command, depending on your version:Terminal

MacOS 11 and 12 (Big Sur, Monterey)

MacOS 10.12 to 10.15 (Sierra, High Sierra, Mojave, Catalina)

Mac OS X 10.7 – 10.9 & 10.11 (Lion, Mountain Lion, Mavericks, El Capitan)

  1. Open Finder and navigate to the > directory and open this ApplicationsUtilitiesTerminal application.
  2. Type the following command.
  3. Enter your password when prompted.
sudo killall -HUP mDNSResponder
image 70
DNS Cache Clearing at MAC 1
image 71
DNS Cache Clearing at MAC 2
image 72
DNS Cache Clearing at MAC 3

Clearing DNS on Linux

Clearing your DNS cache for Linux systems, including Ubuntu, Debian, Red Hat, Fedora, CentOS, etc., will depend on how your system is configured and which service is responsible for DNS caching.

If you are running a system that uses systemd such as Ubuntu or other Debian-based systems, you will need to run the following to clear your DNS cache.

  1. Open a command terminal (run as root or with the following)
  2. Run the following command.
systemd-resolve --flush-caches
  1. Optional. You can verify that this is working correctly by running the following command.
systemd-resolve --statistics

image 3
Arif Akyüz Content Producer Cyber Security Expert

Arif Akyüz
Content Producer & Cyber Security Expert
[email protected]

© 2024 Arif Akyüz. Tüm Hakları Saklıdır. Gizlilik politikası
Yasal Uyarı: Bu sitede yer alan makaleler bilgi amaçlıdır ve hatalar içerebilir. Site sahibi, bu bilgilerin kullanımı sonucunda oluşabilecek zararlardan sorumlu tutulamaz.