NetTest: An IP Network Analyzer

Terrence J. Truta
Columbia University
New York, NY 10027-7003
USA
tjt7@columbia.edu

Abstract

NetTest is a cross platform IP network analyzer written in Java. It uses the shell level tools ping and traceroute in a variety of ways to obtain data and presents it graphically. By using NetTest, one can determine where packets are being lost and del ayed between the local host and any remote host. NetTest also can graph packet loss and delays over a period of time. For example, NetTest can show packet loss and delay statistics at chosen points throughout a day or a week. In addition, NetTest can be c onfigured to test for conditions such as unreachability or heavy packet losses and display an alert message or send an email in response.

Introduction

NetTest has been designed to be straightforward and easy to use. Nevertheless, this section will provide a walk through to illustrate the use of NetTest. Installation instructions are given in a later section of this document. To start NetTest simply use the command:

java NetTest

The following screen will appear:

On this screen you can choose the three modes of tests that were briefly described in the abstract. A standard test will basically run your platforms traceroute program to the remote host specified in the text box on this screen. When completed it will show the results for average delay and packet loss graphically and textually. A thorough test starts with a standard test and then uses your platforms ping utility to ping all of the hosts found with the traceroute utility. This is done to provide more accurate delay and loss statistics. The Internet is well known for its bursty traffic. By running traceroute just once there is a risk of inaccurate statistics for some of the hosts because of this burstiness. Currently a thorough test consists of pinging each host 10 times with 56 bytes of data each. When this test completes it displays the same information as the standard test does but hopefully the data is more accurate.

The continuous test collects delay and loss statistics to one host over a period of time. By default it pings the specified host every 30 minutes for 24 hours. However these values can be changed by clicking on the Options button. The opt ions button is enabled when the Continuous radio button is chosen. The options screen is presented below:

Here you can change the duration and frequency of tests during a continuous test. It is worthy to note that you can change the hours value to a decimal. For example, 0.50 of an hour is 30 minutes, 0.25 of an hour is 15 minutes, and so on. This is primarily useful for testing. The options dialog box also allows you to specify alert conditions. Currently, you can be alerted for the three events shown on the dialog window. These are if the host becomes unreachable, the delay to the host exce eds a specified millisecond value, and/or packet loss exceeds a specified value. The alert for an unreachable host will be generated if all 10 ping attempts for one of the tests in the testing period result in timeouts. The alert for loss will be generate d if the amount of losses for one of the tests exceed the specified number. Note that at most 10 packets can be lost since only 10 packets are sent at one time. The alert for delay is self-explanatory. One special feature for users with Unix and Unix type operating systems (e.g. Linux) is email notification of alerts. If user checks the Send email box and specifies an email address, NetTest will send the user an email if an alert condition is met.

At the completion of one of the tests the following results window is displayed showing the data graphically and textually:

 

The first tab is the graph of the delay data. The graph in the above screen shot shows the delay in milliseconds to each host between my home computer and www.fokus.gmd.de. You can change the graph type by choosing a different type from the combo box a bove the chart. The available types include Line, Bar, and Pie. The data that is used to create this graph can be viewed on the second tab. This data is presented below. Alternatively, you can click directly on the graph point and a message box will pop u p with the host name and IP address. Admittedly it takes good accuracy of the mouse pointer to do this with the thin lines of the line graph. Its easier to take advantage of this feature by using either the bar or pie chart types. The graph and the data f or packet loss appear on the third and fourth tabs respectively. The are presented in a similar fashion as the delay graph and data.

Data used to make the above graph:

Avg Delay Host

--------- ----

142 whp-ny-pm13.netcom.net

133 whp-ny-gw1.netcom.net

139 h3-1-1-nwk-nj-gw1.netcom.net

141 h2-0-ny-nap.netcom.net

143 1-sprint-nap.internetmci.net

144 core3-hssi3-0.WestOrange.mci.net

151 bordercore2.Washington.mci.net

182 166.48.39.254

305 ZR-Frankfurt1.WiN-IP.DFN.DE

312 ZR-Berlin1.WiN-IP.DFN.DE

317 GMD-Berlin1.WiN-IP.DFN.DE

315 KR-GMD-Berlin1.WiN-IP.DFN.DE

322 saturn.fokus.gmd.de

 

Architecture

Needless to say since NetTest is written in Java, it exhibits an object-oriented design and architecture. The essential classes are shown in the following use case.

 

The user interacts with the two interface classes, StartGUI and DisplayGUI. After the user presses the start button on the StartGUI object, his or her choice for remote host are sent to the appropriate wrapper classes. The NetTest class mediates the me thod calls to TracertWrapper and PingWrapper. This design choice will make adding another interface such as a text-based interface relatively easy. The TracertWrapper object makes one call to the traceroute shell level program of the operating system and parses the output to get the data. TracertWrapper sends a progress update to StartGUI after every line it parses. In contrast, PingWrapper makes 10 separate calls to the ping utility in succession at a time. For the thorough test type every host found in the traceroute is pinged 10 times. For the continuous test type the host is pinged 10 times only once in a while. In any case, the progress bar is updated by the NetTest object after a call to PingWrapper. After the tests are run the data is sent to the D isplayGUI object where it is displayed for the user.

 

Some helper objects that aren't shown the the above diagram. They include a dialog window showing the options for a continuous test (shown in the previous section) and a message box object. In addition, there are two classes that act as C structures. T he AutoOptions object stores the user's options chosen for the continuous test. This handy object reduces the amount of 'get' and 'set' access functions from 26 to 2! In a similar way the ChartData object makes like easier. It stores the data obtained fro m TracertWrapper and PingWrapper. All together there are 9 public classes.

Limitations

NetTest doesn't work unless the traceroute and ping utilities are available. Fortunately these tools are usually found on hosts that are connected to an IP network. A more significant limitation is that the formats of the outputs of these utilities var y from platform to platform. NetTest has been successfully executed on Windows95, Solaris, and Linux. However, operating system specific code was needed to deal with idiosyncrasies that exist between each of them. It is likely that modifications will be n eeded for NetTest to run properly on an untested platform. Currently the code expects the output from these utilities to be the same on all Microsoft Windows operating systems (e.g. Windows95/98/NT) and it expects all Unix operating systems to have utilit ies that have same output as Solaris' ping and traceroute. Linux is treated as a special case in the code that parses output from the Unix based tools.

Other minor limitations include the lack of email alert functionality for windows users and a slightly distorted GUI when running under Unix.

Future Enhancements

Some future enhancements include:

Related Work

Related work can be found at Henning Schulzrinne's Short-Term (Real-Time) Traffic, Loss and Delay Statistics web page. NetTest is different from other related work since it allows the user greater control over what is measured. Many existing efforts only give an overview of traffic in an area or give statistics only between one web site and your computer. NetTest allows the user to see graphically the delay and loss statistics to any h ost. NetTest also features an enhancement of the standard traceroute program by incorporating ping to provide more accurate data. In addition, NetTest allows the user to effortlessly monitor a route to a remote host for long period of time. The user can u se this information to determine the best time of the day or week for a multimedia conference. NetTest also includes alert mechanisms so a user can always stay informed of traffic changes even when they aren't actively using the application.

Installation

 To install NetTest:

  1. Download the archive:
  1. Unpack the archive.
  1. Add nettst.zip to the CLASSPATH environment variable. NOTE: you do not have to unzip nettst.zip
  1. Type javac *.java in the directory you unpacked the files.
  2. Type java NetTest to run the program.


Last updated: 1998-08-02 by Terrence J. Truta