Browse by Topic Pre-Sales & Policies Hosting Guide cPanel WebHost Manager (WHM) Plesk SSL Certificates Specialized Help Offers & Bonuses Affiliates Helpful Resources Account Addons Billing System HostGator Blog HostGator Forums Video Tutorials Contact Us Interact and Engage
spacer spacer spacer

HostGator.com » Support Portal

[?]
Support Portal Home » Hosting Guide » Let's Get Started » DNS & Name servers » Flush DNS

Flush DNS

Sometimes there is an issue with your DNS resolvers caching the domain name to IP mapping. When you're trying to go to the domain, it's actually pulling up an old IP address instead of looking for a new one and finding the correct record. So, to expedite this very common problem of cached DNS, please do the following steps.


Microsoft Windows Vista and Windows 7

Close your application (e.g. browser or email).

Click the Start orb and follow All Programs > Accessories, look for Command Prompt. Be sure to right click on Command Prompt and choose "Run as Administrator". When the black screen appears, type the following command and hit enter.

ipconfig /flushdns

Restart your application (e.g. browser or email).


Microsoft Windows XP

Close your application (e.g. browser or email).

Go to the Start menu, choose Run, type cmd and hit OK. When the black screen appears, type the following command and hit enter.

ipconfig /flushdns

Restart your application (e.g. browser or email).


Mac OSX

Navigate to your Applications folder, open Utilities, and double click on Terminal. Type the following command and hit enter.

dscacheutil -flushcache

That command should work on Mac OS X 10.5 (Leopard), 10.6 (Snow Leopard) and 10.7 (Lion). If the above command is not available, you can try the other flush DNS command as follows which should work on Mac OS X 10.4 (Tiger):

lookupd -flushcache

Don't worry if either command says something like "Not found".

Restart your application (e.g. browser or email).


Linux

Note: Different distributions and versions of Linux may have slightly different commands due to differences in configuration. One of the commands below will probably work.

Open up a root terminal window (Ctrl+T in Gnome). Type the following command and hit enter.

/etc/init.d/nscd restart

You may need to use sudo depending on your installation instead:

sudo /etc/init.d/nscd restart

Some distributions support this command:

sudo /etc/init.d/dns-clean start

Or support this command:

sudo service nscd restart

Some installations may have NSDS located in another directory, like the following example. You may need to locate where it is installed to be able to execute the correct command.

/etc/rc.d/init.d/nscd restart

Restart your application (e.g. browser or email).

Related Articles

  • Do you offer Telnet?
  • How do I clear my web browser's cache?
  • Traceroute, whois, ping, and dig.

Was this article helpful to you?

Article Comments

spacer spacer
ian
For Ubuntu distribution of Linux:

Ubuntu does not cache DNS unless the package nscd has been installed. If you get a command not found when using the command "/etc/init.d/nscd restart" then all you need to worry about is clearing Firefox dns cache.

Posted: January 30, 2011
spacer spacer
John Walker
great service hostgator

Posted: August 18, 2011
spacer spacer
Jason
Following this the command prompt responded that the request "required elevation".

I did not climb a mountain to try again. HAH.

Posted: September 30, 2011
spacer spacer
HostGator
Thank you for your comments. Just a quick reminder that the comments on this page are not monitored by technical support staff, and that for support issues, it is best to contact us by live chat, phone or email so we can assist you right away.

Although comments are not monitored by technical support staff, they are moderated and read by technical writers. Comments will need to be approved by a moderator before appearing.

Our technical writers do read the comments periodically for the purposes of updating the articles, and do appreciate your feedback, suggestions and corrections to the articles themselves, as well as any suggestions or tips for readers of this article. However, support questions posted here are not guaranteed to be replied to in a timely manner or at all. For support issues, it is best to contact our support staff instead by live chat, email or phone.


Posted: December 13, 2011 (Global Reply)

Your comments help us keep the knowledge base updated. This is not a medium for support. If you have questions or need help, please contact us via email, phone or live chat for fast assistance.

Post Comment

  • Our Services
  • Web Hosting
  • Reseller Hosting
  • VPS Hosting
  • Dedicated Servers
  • Domain Names
  • Application Hosting
  • Windows Hosting
  • Help and Support
  • Support Portal
  • Video Tutorials
  • Forums
  • Ticket System
  • Billing System
  • Live Chat
  • Company
  • About the Company
  • Management Team
  • Network/Datacenter
  • Awards & Reviews
  • Press & Media
  •  
  • HostGator Coupons
  • Company Blog
  • Contact Us
  • Affiliates
  • Careers
  • Legal
  • Terms of Service
  • Privacy Policy
  • Copyright
gipoco.com is neither affiliated with the authors of this page nor responsible for its contents. This is a safe-cache copy of the original web site.