Author Topic: (SOLVED) DNS cache flush  (Read 2617 times)

Online Yankee

  • Hero Member
  • *****
  • Posts: 1488
  • In theory, theory=practice, in practice ???
(SOLVED) DNS cache flush
« on: April 18, 2012, 01:03:39 PM »
Recently am having problems staying connected to the internet
with AT&T.    The tech suggested I perform a DNS cache flush
just like they do on Windows.   Could resolve the whole problem.

Well the Linux command I found doesn't work as the daemon is
not installed or available thru Synaptic.

Would help eliminating the computer as the source of the problem
and focus on the modem, which usually starts the internet up when
reset and the connection reinstalled, reconnecting the DNS server
and the Configuration server again thru the reset modem process.

Any help with the DNS cache flush command would be appreciated.

Thanks,

Patrick
« Last Edit: April 18, 2012, 05:17:39 PM by Ferdes Fides »
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE

Online Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: DNS cache flush
« Reply #1 on: April 18, 2012, 01:14:12 PM »
I know little of this ....  but always assumed that unless I was running a DNS server I would not either have DNS cache or the need to purge it .....  and we all know what assumptions do  :(

What is the package name you referred to above?
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline menotu

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 15310
  • ┌∩┐(◕_◕)┌∩┐
Re: DNS cache flush
« Reply #2 on: April 18, 2012, 01:21:55 PM »
I found  this

To flush the DNS cache in Linux, restart the nscd daemon:-

    - To restart the nscd daemon, type /etc/rc.d/init.d/nscd restart in your terminal

    - Once you run the command your linux DNS cache will flush.

===================

I think this will need to be done as root
PCLinuxOS 32bit KDE 4.10.1; kernel-3.4.11-pclos1.bfs & 64bit 3.2.18bfs; NVidia GeForce 8400GS 1GB 310.19 driver

Sony Vaio SVE1513A4ESI Laptop, Intel Core i5, 2.6GHz, 6GB RAM, 750GB, 15.6" Intel HD Graphics 4000

Offline muungwana

  • Hero Member
  • *****
  • Posts: 6246
Re: DNS cache flush
« Reply #3 on: April 18, 2012, 03:03:33 PM »
Recently am having problems staying connected to the internet
with AT&T.    The tech suggested I perform a DNS cache flush
just like they do on Windows.   Could resolve the whole problem.


you can tell if the problem is DNS related by trying to go online using an IP address vs going online using a name addresses.

If using name fail but using ip pass,then the problem is DNS related.If using IP addresses fail, then the problem is connectivity.

Test to make sure you can go online and DNS is working

ping -c 1 google.com

expected result:
Quote
PING google.com (74.125.226.232) 56(84) bytes of data.
64 bytes from lga15s29-in-f8.1e100.net (74.125.226.232): icmp_req=1 ttl=53 time=55.5 ms

--- google.com ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 55.540/55.540/55.540/0.000 ms

Test to make sure you can go online(not using dns)

ping -c 1 8.8.8.8

expected result:
Quote
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_req=1 ttl=50 time=50.1 ms

--- 8.8.8.8 ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 50.154/50.154/50.154/0.000 ms

The line to look for is in red, If 100% of packets are lost then the test fail
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Online Yankee

  • Hero Member
  • *****
  • Posts: 1488
  • In theory, theory=practice, in practice ???
Re: DNS cache flush
« Reply #4 on: April 18, 2012, 04:35:07 PM »
The nscd daemon doesn't appear to exist, the other commands run
give 0% packet loss.   So, I'll make a copy of this thread and run the
commands to tell the AT&T tech the results.     Thank You.

The good news is I've had to reset the modem several times to
reconfigure the connection and the tech said one more time
and he's pretty sure a new modem will be req'd.    But, he wanted to
see the DNS test results or what happens after a DNS cache flush to make sure, 
so not my motherboard, but the AT&T modem losing the connection info
is the direct cause of the problem reoccurring, and that would be confirmed.

He didn't know the Linux command, just the Windows command for the
info you provided and needed to be provided for that.

Much obliged.

THX.

Patrick
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE

Offline phd7

  • Jr. Member
  • **
  • Posts: 15
Re: (SOLVED) DNS cache flush
« Reply #5 on: April 19, 2012, 02:27:49 PM »
what modem are you using?
I had the same problem with a sierra. Recently bought a Huawei E353 and problem disappeared.

Curiously, this only happened with gnome network manager or nm applet...never with KDE network manager.

have you tried it with a KDE distro?

Online Yankee

  • Hero Member
  • *****
  • Posts: 1488
  • In theory, theory=practice, in practice ???
Re: (SOLVED) DNS cache flush
« Reply #6 on: April 20, 2012, 02:16:46 PM »
what modem are you using?
I had the same problem with a sierra. Recently bought a Huawei E353 and problem disappeared.

Curiously, this only happened with gnome network manager or nm applet...never with KDE network manager.

have you tried it with a KDE distro?

The modem is an AT&T 2WIRE on an LXDE2010 which I use primarily.
Don't have KDE presently installed, just a couple LXDE's and a couple
OpenBox's.

Off a phone line I'm expecting it to work for 2 or 3 weeks and need
another modem reset, which takes a hour to do with waiting for
the connections all to reset then.    Don't know.    The DNS flush
doesn't seem to be how the computer is working.   I'll probably
need a new modem from AT&T eventually.    Have had it for over
a year and a half now.

Patrick
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE

Offline phd7

  • Jr. Member
  • **
  • Posts: 15
Re: (SOLVED) DNS cache flush
« Reply #7 on: April 20, 2012, 03:14:12 PM »
The modem is an AT&T 2WIRE on an LXDE2010 which I use primarily.
Don't have KDE presently installed, just a couple LXDE's and a couple
OpenBox's.

Off a phone line I'm expecting it to work for 2 or 3 weeks and need
another modem reset, which takes a hour to do with waiting for
the connections all to reset then.    Don't know.    The DNS flush
doesn't seem to be how the computer is working.   I'll probably
need a new modem from AT&T eventually.    Have had it for over
a year and a half now.

Patrick

have you had a look at syslog after a crash for more info?

Online Yankee

  • Hero Member
  • *****
  • Posts: 1488
  • In theory, theory=practice, in practice ???
Re: (SOLVED) DNS cache flush
« Reply #8 on: April 20, 2012, 03:34:21 PM »
have you had a look at syslog after a crash for more info?

Today it says I'm connected to the modem Gateway and another IP address I
recognize, but doesn't mention the AT&T DNS server or the AT&T Configuration
server.    They have to receive my ping signal from the modem and sometimes they don't. 
They have IP adresses also, so the ping commands in this thread should help
to confirm or not confirm that.   Today it works OK.
   
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE