Menu

Long Distance Troubleshooting

Long Distance Troubleshooting Example

Most Wide Area debugging exercises start the same way - indication that there is a problem between two sites.  Most network users don't know (and are unable to easily find) the details of the network path between the resources they are using.  Indeed, many networks do not publish maps, or may refuse to provide them when asked. However, perfSONAR provides tools which can help understand the path, and we can use tools to help us draw a map and solve the problem. 

In the example below we have two sites.  One is a National Laboratory and the other is a Campus.  The campus reports that it is having trouble downloading data from the National Laboratory. The Lab and University both have a good idea of their local network (and can provide a diagram when talking to each other), but they don't have a detailed understanding of the wide area path between them.  Lets start with the first map, a view of each site having the problems and a clear indicator which direction is having a hard time.  We can draw the things we don't know about as a cloud for now:

How can we tell what is in the middle?  We would typically use the traceroute tool, but this is only good about giving us a single direction, and without perfSONAR we need to have a login on the host where we wish to run traceoute. perfSONAR has a special tool that allows us the ability to run a traceroute between any pair of perfSONAR servers, and we don't need to be logged in to either.  Consider these examples:

[dart@denv-pt1 ~]$ pscheduler task trace --source bost-pt1.es.net --dest perfsonar.nersc.gov
Submitting task...
Task URL:
https://bost-pt1.es.net/pscheduler/tasks/e65ea249-5ee9-41b7-a240-28005f9cc912
Running with tool 'traceroute'
Fetching first run...

Next scheduled run:
https://bost-pt1.es.net/pscheduler/tasks/e65ea249-5ee9-41b7-a240-28005f9cc912/runs/c78545c8-f160-4006-b52c-359a1cabf4c0
Starts 2018-05-03T09:11:30-07:00 (~7 seconds)
Ends 2018-05-03T09:11:38-07:00 (~7 seconds)
Waiting for result...

1 bostcr1-bostpt1.es.net (198.124.238.65) AS291 0.3 ms
ESNET-EAST - ESnet, US
2 starcr5-ip-a-bostcr5.es.net (134.55.218.190) AS293 21.9 ms
ESNET - ESnet, US
3 chiccr5-ip-b-starcr5.es.net (134.55.42.45) AS293 22.3 ms
ESNET - ESnet, US
4 kanscr5-ip-a-chiccr5.es.net (134.55.43.82) AS293 33.6 ms
ESNET - ESnet, US
5 denvcr5-ip-a-kanscr5.es.net (134.55.49.57) AS293 43.6 ms
ESNET - ESnet, US
6 sacrcr5-ip-a-denvcr5.es.net (134.55.50.201) AS293 64.5 ms
ESNET - ESnet, US
7 sunncr5-ip-a-sacrcr5.es.net (134.55.40.6) AS293 67.6 ms
ESNET - ESnet, US
8 sunn-cr5-br1.nersc.gov (198.129.78.34) AS292 68.9 ms
ESNET-WEST - ESnet, US
9 br1-cr1.nersc.gov (128.55.192.110) AS2936 68.8 ms
NERSC - National Energy Research Scientific Computing Center, US
10 perfsonar.nersc.gov (128.55.199.18) AS2936 68.3 ms
NERSC - National Energy Research Scientific Computing Center, US

No further runs scheduled.
[dart@denv-pt1 ~]$

This gives us the path between the ESnet perfSONAR test host in Boston and the perfSONAR test host at the NERSC supercomputer center in Berkeley CA. 

[dart@denv-pt1 ~]$ pscheduler task trace --source perfsonar.nersc.gov --dest bost-pt1.es.net
Submitting task...
Task URL:
https://perfsonar.nersc.gov/pscheduler/tasks/cd7f05fc-5027-4103-8a3f-48a194c08699
Running with tool 'traceroute'
Fetching first run...

Next scheduled run:
https://perfsonar.nersc.gov/pscheduler/tasks/cd7f05fc-5027-4103-8a3f-48a194c08699/runs/b72e9b68-c96e-44ed-9738-74f3aad76754
Starts 2018-05-03T09:14:13-07:00 (~7 seconds)
Ends 2018-05-03T09:14:21-07:00 (~7 seconds)
Waiting for result...

1 128.55.199.22 AS2936 0.1 ms
NERSC - National Energy Research Scientific Computing Center, US
2 cr2-br1.nersc.gov (128.55.192.113) AS2936 0.5 ms
NERSC - National Energy Research Scientific Computing Center, US
3 sunncr5-nersc.es.net (198.129.78.33) AS292 1.9 ms
ESNET-WEST - ESnet, US
4 sacrcr5-ip-a-sunncr5.es.net (134.55.40.5) AS293 4.5 ms
ESNET - ESnet, US
5 denvcr5-ip-a-sacrcr5.es.net (134.55.50.202) AS293 25.5 ms
ESNET - ESnet, US
6 kanscr5-ip-a-denvcr5.es.net (134.55.49.58) AS293 36.1 ms
ESNET - ESnet, US
7 chiccr5-ip-a-kanscr5.es.net (134.55.43.81) AS293 47.1 ms
ESNET - ESnet, US
8 starcr5-ip-b-chiccr5.es.net (134.55.42.46) AS293 47.2 ms
ESNET - ESnet, US
9 bostcr5-ip-a-starcr5.es.net (134.55.218.189) AS293 69 ms
ESNET - ESnet, US
10 bost-pt1.es.net (198.124.238.66) AS291 68.5 ms
ESNET-EAST - ESnet, US

No further runs scheduled.
[dart@denv-pt1 ~]$

This second run, with source and destination hosts swapped, give us the other direction.

This illustrates an important capability. While logged on to a host that has a perfSONAR tool installed (the ESnet perfSONAR host in Denver, Colorado in this case), we can run a traceroute between any two other perfSONAR hosts (provided those hosts permit such action, as most perfSONAR hosts on science networks do). This allows us to learn the layer 3 (network layer) path between the hosts.  We can see the networks the path traverses, and get a rudimentary view of latency. There may be details that we don't get about the lower layers of the network, but it helps us to establish the networks in the path, and build a map of the path we need to debug. 

Back to our example, we can use pScheduler to run the traceroute tool between the perfSONAR nodes at the Lab and University and we determine the network path:

  • Lab LAN
  • ESnet
  • Internet2
  • Regional Network
  • Campus LAN

We can be as detailed as possible, and try to indicate the number of hops and evices we cross, along with estimations of the latency.  How can we get the exact latency numbers?  We will use ping.  As in the example above, ping usually is only helpful if we are on one of the hosts.  We use perfSONAR to measure the round trip time between the two hosts:

[dart@denv-pt1 ~]$ pscheduler task rtt --source perfsonar.nersc.gov --dest bost-pt1.es.net
Submitting task...
Task URL:
https://perfsonar.nersc.gov/pscheduler/tasks/de70dace-e615-4ac5-92c0-d1ff06fe7573
Running with tool 'ping'
Fetching first run...

Next scheduled run:
https://perfsonar.nersc.gov/pscheduler/tasks/de70dace-e615-4ac5-92c0-d1ff06fe7573/runs/14b23220-6c40-4069-81fa-7b6a469a674f
Starts 2018-05-03T09:20:56-07:00 (~7 seconds)
Ends 2018-05-03T09:21:07-07:00 (~10 seconds)
Waiting for result...

1 bost-pt1.es.net (198.124.238.66) 64 Bytes TTL 55 RTT 68.3000 ms
2 bost-pt1.es.net (198.124.238.66) 64 Bytes TTL 55 RTT 68.3000 ms
3 bost-pt1.es.net (198.124.238.66) 64 Bytes TTL 55 RTT 68.4000 ms
4 bost-pt1.es.net (198.124.238.66) 64 Bytes TTL 55 RTT 68.3000 ms
5 bost-pt1.es.net (198.124.238.66) 64 Bytes TTL 55 RTT 68.6000 ms

0% Packet Loss RTT Min/Mean/Max/StdDev = 68.314000/68.413000/68.641000/0.310000 ms

No further runs scheduled.
[dart@denv-pt1 ~]$

And in the opposite direction:

[dart@denv-pt1 ~]$ pscheduler task rtt --source bost-pt1.es.net --dest perfsonar.nersc.gov
Submitting task...
Task URL:
https://bost-pt1.es.net/pscheduler/tasks/b713edc5-d489-40bb-9a7d-a13544726ae5
Running with tool 'ping'
Fetching first run...

Next scheduled run:
https://bost-pt1.es.net/pscheduler/tasks/b713edc5-d489-40bb-9a7d-a13544726ae5/runs/7e737d1d-36c5-47da-9d4d-4e8873ec14c3
Starts 2018-05-03T09:24:37-07:00 (~8 seconds)
Ends 2018-05-03T09:24:48-07:00 (~10 seconds)
Waiting for result...

1 perfsonar.nersc.gov (128.55.199.18) 64 Bytes TTL 55 RTT 68.3000 ms
2 perfsonar.nersc.gov (128.55.199.18) 64 Bytes TTL 55 RTT 68.3000 ms
3 perfsonar.nersc.gov (128.55.199.18) 64 Bytes TTL 55 RTT 68.3000 ms
4 perfsonar.nersc.gov (128.55.199.18) 64 Bytes TTL 55 RTT 68.6000 ms
5 perfsonar.nersc.gov (128.55.199.18) 64 Bytes TTL 55 RTT 68.5000 ms

0% Packet Loss RTT Min/Mean/Max/StdDev = 68.339000/68.448000/68.615000/0.308000 ms

No further runs scheduled.
[dart@denv-pt1 ~]$

While logged on to a host that has a perfSONAR tool installed, we can measure the round trip time (or "latency") between any two other perfSONAR hosts.

With these two tools, we can learn a lot about the network - but what we really need to know is where there may be more perfSONAR hosts located.  Ideally we want to know if there is a host at each hop along our path.  The perfSONAR consortium maintains an extensive directory of perfSONAR resources, each node will register to this when it comes online.  To view a portion of this, visit the following web site:

http://stats.es.net/ServicesDirectory/

This GUI allows us to ask questions about perfSONAR nodes.  E.g. where they are deployed, what services they are running.  With our traceroute information above, we know which networks to search for hosts.  Using traceroute and ping, we then start to fill out a new graph that shows several things:

  • The semi-exact layer 3 path between the problem hosts
  • The location of perfSONAR nodes along the path
  • The relative latencies between perfSONAR nodes, and domains

The new map appears below:

With this in place, we can now focus on debugging. One may be tempted to try to debug each link directly: this is the worst way to approach the problem. Remember that TCP dynamics will be different depending on the latency between the ends.  According to our packet loss graph (https://fasterdata.es.net/network-tuning/tcp-issues-explained/packet-loss/) we only start to see that packet loss is an issue as the latency increases.  Debugging the links within a campus, where the latency is 1ms, won't be very productive, we will usually see high throughput, even if there are problems. For example, if we tested between the Border and DMZ perfSONAR nodes on either campus, we should see close to line rate performance, even with some packet loss. 

Because TCP will react differently as latency increases we need to develop a new strategy: find the path that is longest and also highest performing.  This may seem counter intuitive, e.g. looking far away from a problem to try to fix it, but we are using the weakness of TCP (performance sensitivity to packet loss) to our advantage.

In the map below, it was shown that ESnet to the regional, crossing Internet2, a path of 47ms, was completely clean in each direction:

 

However, once we go into the University network, performance falls - but only in one direction:

What can we say at this point:

  1. The long path between the University and the Lab (crossing ESnet, Internet2, and the Regional) shows dirty downloads (e.g. Lab -> University). 
  2. The long path between ESnet, Internet2, and the Regional is completely clean - it shows fast performance in each direction
  3. The long path between the University and ESnet (crossing ESnet, Internet2, and the Regional) shows dirty downloads (e.g. ESnet -> University).
  4. Because of #2, we want to center our investigation within the campus, and between the campus and the regional (on the campus side). 

How did we come to the conclusion in #4?  TCP doesn't lie, a long path that performs well is free of errors. This can basically rule out the ESnet/Internet2/Regional portion.  We now start to examine the setup on campus:

  • Investigate SNMP to see if we see any counters that show high utilization, packet drops, or errors
  • Check the settings on switches and routers in the path, to be sure they have enough memory to support high performance transfers (e.g. check the BDP calculator)

Investigation on the campus found the issue:

The border device was recently changed, and featured default settings on one of the interfaces.  The lack of available buffering caused there to be a large number of dropped backs when people were downloading.  Fixing the buffer caused performance to return back to a normal level.

This example is very detailed, but should give enough information to debug a long path problem.