com.buzzsurf.dns
Class SpeedTest
java.lang.Object
|
+--com.buzzsurf.dns.SpeedTest
- public class SpeedTest
- extends java.lang.Object
This class tests the speed of DNS resolutions by looking up the IP Addresses
of multiple domain names. It reads the domain names from file you
specify on the command like, 1 name per line.
There are a number of important things to consider when speed testing your
DNS resolution system!
- Run this test multiple times. The first time will almost always
be slower than subsequent tests, because after resolving the name once,
your DNS server will cache it locally.
- Run this test with different data sets. Try using a data set with
all distinct domain names, and then a data set with some duplicate domain
names. Your performance should be better on the duplicate test because
of local caching.
- Run this test with different thread counts to see what happens.
You can place a very heavy load on a DNS server by setting the thread
count high. Your DNS server may perform well at a light load, but fail
during heavy load. Watch your HNF% to see this.
- Your network, DNS server, local machine, and the resolver you are
using can all effect performance.
- The standard Java 1.4 resolver uses native calls. This can be
fast in some cases, but has been found to be a bottleneck under
heavy load because of synchronization.
- Does your resolver use TCP or UDP by default? TCP based resolvers
are generally much slower.
- What kind of DNS server are you using? Our tests have shown that
Bind 9 is a great performer, and Microsoft DNS Server ineviatably
produces high HNF% over time and under load. There are other
commercial solutions available that may be a good choice as well.
- It is very important that you don't consider speed alone, but also
the number of failed resolutions (Host Not Founds (HNFs)) you get. We
have found that your HNF% is intimately related to the current load on
your DNS server.
- Version:
- 0.9
- Author:
- Paul Cowan (pwc21@yahoo.com)
|
Constructor Summary |
SpeedTest(java.lang.String inputFileName,
int numThreads)
|
|
Method Summary |
static void |
main(java.lang.String[] args)
|
protected java.lang.String |
nextDomain()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SpeedTest
public SpeedTest(java.lang.String inputFileName,
int numThreads)
main
public static void main(java.lang.String[] args)
nextDomain
protected java.lang.String nextDomain()