I keep getting an error message whenever doing anything that requires a DNS lookup on my CentOS server. E.g.:
[root@15557 etc]# wget http://www.whitehouse.gov/sites/default/files/rss_viewer/birth-certificate-long-form.pdf --2011-05-03 20:55:35-- http://www.whitehouse.gov/sites/default/files/rss_viewer/birth-certificate-long-form.pdf Resolving www.whitehouse.gov... failed: Temporary failure in name resolution. wget: unable to resolve host address `www.whitehouse.gov'
If I restart the server then this problem goes away for a short time, but it always comes back after an hour or so. If I change the nameserver IPs listed in resolv.conf
, the problem is not fixed, even if I substitute them with common nameserver like Google's 8.8.8.8
. If I flush the hosts cache after changing resolve.conf
, it does not fix the problem either. After restart of the server, the resolv.conf
is changed back to it's default values (I guess by some DHCP).
tcpdump
is readily availalble in most distros via their package repository. I'd recommend googling around for a tcpdump tutorial before getting started, though. Also, you can use tcpdump to capture the packets and write them to a log file, then you can open up that log file in a GUI tool called Wireshark, which is a bit more user-friendly than using the CLI.