Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How to query client  socket (DNS) name cache?

Posted on 1998-11-14
5
197 Views
Last Modified: 2013-12-23
  We are beginning a long-term transition from WINS to DNS at our shop, and I'm getting comfortable with the server side of DNS. However, I'd like to be able to have more client side understanding. I'm getting comfortable with nslookup, but want more *client* side info than nslookup provides.

   Specifically, I want to be able to query (as opposed to clear) the client's "DNS" cache, preferrably the entire cache, but will settle for a single name if I have to. I want to be able to see the time remaining in the TTL for a name. I know arp -a and nbtstat -c are similar utils to what I'm looking for, but they don't do this.

   What utility (or API) will? I'm really interested in the answer to this for every OS I'll be working with: NT, 95/98, AIX, Solaris, Linux, but will clearly be happy if I can get the answer for NT and 95/98.

   Thanks in advance!
0
Comment
Question by:morgan1
  • 2
  • 2
5 Comments
 

Expert Comment

by:dsrikump
ID: 1565770
morgan1,
 I'm sort of confused by your question. Are you asking about how to find out what's in a clients arp cache? Or are you trying to find out about how to learn more about different clients and servers located elsewhere on a network?

 In the case that you are looking to find out more about utilities that can be used to find out more about other clients, you need look no further than what's in the standard TCP/IP suite. There is the "ping" command used to send a query packet to another host to determine if it can receive and respond to packets. There is "tracert" (traceroute in almost everyone else's vocabulary except windows) which can help you determine where your packets are going and how many "hops" it takes to get there. This can tell you about TTL decrementation as well.

 If that wasn't what you were looking for then please rephrase the question. Thanks and good luck!
0
 

Expert Comment

by:dsrikump
ID: 1565771
Looks like I forgot to add something.

"ipconfig /all" is a great command for finding out information that you are sitting at.

If you were looking to find out what's in other machines arp cache, this might be an exercise in futility because it is a very dynamic file that changes every 12 minutes or so. WinNT and 95 both flush the arp cache of entries that are not marked as static after about 12 minutes. But if this is indeed what you want to do then you can install rconsole from the NT resource kit on the machine that you want to execute commands on and run rclient from your machine. This supposedly acts like a telnet client! Then you should be able to execute the arp -a command and see the results in your rclient window. Although I have never had to do this first-hand.
0
 

Author Comment

by:morgan1
ID: 1565772
  Sorry, I thought that I had been specific enough the first time. What I want to look at is NOT the client's ARP cache, which tracks the association between IP to MAC on the client, but the client's NAME cache, which tracks the association from NAME to IP. My DNS server has one of these, and my client does, too. On the NetBIOS side, the NBTSTAT -c command shows the Microsoft *equivalent* to the information I'm seeking about DNS on my client PC.

   For instance, if I ping www.experts-exchange.com from my PC, my company DNS server will talk to the DNS servers on the Internet to locate the DNS records for this DNS name. My DNS server caches the response in it's cache before delivering the answer to my PC. My understanding is that my PC caches the answer, too, so that it doesn't requery my DNS server if I immediately re-ping that web server. I want to be able to look at my PC's name cache. I am interested in this largely as a troubleshooting tool. If I adjust the TTL on a DNS name or domain that I administer on my company's DNS server, I want to be able to monitor the effect within the network by DNS clients as they use that name.

   I want to understand the environment that I support as much as possible and be able to monitor the effect of changes that I make to that environment. I guess that I can fall back to sniffing the network beside my client when performing the testing, but consider that to be an inelegant solution to this question.

   Again, any thoughts or ideas would be appreciated. Thanks!
0
 
LVL 2

Accepted Solution

by:
irp earned 100 total points
ID: 1565773
Your PC (Client) does *not* cache DNS entries. I thought it did but I just did a little test. Load www.experts-exchange.com, stop DNS on DNS server, reload www.experts-exchange.com. It didn't work. Hence, PC (Win95) does not cache DNS.
0
 

Author Comment

by:morgan1
ID: 1565774
Fair enough. This mirrors my own suspicion, and probably holds true on NT as well. Thanks for your input on this.
0

Featured Post

Connect further...control easier

With the ATEN CE624, you can now enjoy a high-quality visual experience powered by HDBaseT technology and the convenience of a single Cat6 cable to transmit uncompressed video with zero latency and multi-streaming for dual-view applications where remote access is required.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A common practice in small networks is making file sharing easy which works extremely well when intra-network security is not an issue. In essence, everyone, that is "Everyone", is given access to all of the shared files - often the entire C: drive …
Trying to figure out group policy inheritance and which settings apply where can be a chore.  Here's a very simple summary I've written which might help.  Keep in mind, this is just a high-level conceptual overview where I try to avoid getting bogge…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

789 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question