View JDK DNS cache

Hi,

I am making some comparisons over IPv4 and IPv6 response times over a high load. I am creating an IPv4 baseline and disabled IPv6 in the JDK and in the kernel networking. Is there any way to view the IP addresses in the JDK DNS cache during a simulation run?

Many Thanks

Aidy

Not I’m aware of.

This looks similar to what you’re trying to do (Java example):

http://stackoverflow.com/questions/1835421/java-dns-cache-viewer

I had to change one line before it would compile and run:

Field af = cacheEntryKlass.getDeclaredField(“address”);
to:
Field af = cacheEntryKlass.getDeclaredField(“addresses”);

Does that help at all?

Cheers,
Barry