Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 02-12-2017, 06:05 PM   #1
Registered: Apr 2016
Posts: 466

Rep: Reputation: Disabled
How to flush the DNS cache?

I am using Linux Mint 17.3 Rosa Cinnamon.

Is shutting down and turning off the computer and the modem-router, and then turning them back on again, always sufficient to flush the DNS cache?

If not, what do I need to do please? The instructions I have found on the internet vary considerably according to the particular variety of Linux used, and there seems to be several lines of terminal code to enter.

Old 02-12-2017, 10:10 PM   #2
Registered: Oct 2009
Location: Colorado, USA
Distribution: I use Arch btw
Posts: 142

Rep: Reputation: 12
If your problem is with DNS not updating, it's almost always a problem with your upstream DNS server. You can view the name servers you are using with:

nmcli device show <interfacename>
Obviously replace <interfacename> with your actual interface name. If you don't know the name of your network interface, paste the output of
sudo ifconfig
here and we can show you how to find it.

If it lists the name server as the same IP address as your router, then you likely have some DNS caching going on on your router. Restarting it will likely flush its cache. Certain routers are notorious for caching DNS records for an obscene amount of time, so if your network is currently set up like this, I recommend changing your router's DHCP options to distribute OpenDNS or Google DNS name servers. Doing this, you can avoid many problems caused by DNS caching.
Old 02-13-2017, 02:27 AM   #3
LQ Addict
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052Reputation: 6052
i have nothing to say on the topic (yet) but i remember that op has been posting about dns servers:
i think this might help to assess the current situation.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Howto flush dns cache rkfb Slackware 6 06-15-2022 05:04 PM
how to flush dns cache SarahGurung Linux - Newbie 2 10-18-2011 07:05 AM
how-to flush dns cache PlatinumRik Linux - Networking 6 07-27-2011 03:47 PM
Display and Flush DNS cache click Linux - Networking 7 11-10-2009 02:00 PM
DNS Cache Flush not Working!!!! thaj Linux - Networking 0 11-21-2007 04:21 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 05:47 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration