Traceroute Games
Posted on January 07, 2005 by oubiwann

This post is actually taken from and email that I wrote to some friends (late last December) who like this kind of stuff. I went searching through my email, looking for what it was that I did with pydot and graphviz just a while back, and I realized I never blogged about it, and I should have ;-)
A few days after the Winter Solstice, I was screwing around with pydot (graphviz) and a custom traceroute python wrapper I threw together (Update: this is now available here). I wanted to graphically visualize multiple traceroutes and see the paths shared in common. This is part of a proof-of-concept for some monitoring ideas I have.
The end result was rather cool, the images for which are available here. Here's the Python code that generated the images (though all the heavy lifting is done by the traceroute module, linked to above):
import pydot
from adytum.net import traceroute
hosts = ["www.google.com", "www.amazon.com", "www.aol.com", "www.cnet.com",
"www.yahoo.com"]
linkedHosts = []
for host in hosts:
trace = traceroute.Trace(host, useDNS=True, queries=5)
trace.run()
domains = trace.results.getLinkedDomains(subdomainLimit=2)
linkedHosts.extend(domains)
graph = pydot.graphfromedges(linkedHosts, directed=True)
graph.write_png("traceroutes.png", prog="dot")
Author | oubiwann |
---|---|
Date | January 07, 2005 |
Time | 01:17:08 |
Category | |
Tags | graphviz monitoring networking pydot pymon python visualization |
Line Count | 1 |
Word Count | 303 |
Character Count | 4125 |
Comments?
This blog doesn't use standard (embedded) comments; however, since
the site is hosted on Github, if there is
something you'd like to share, please do so by
opening a
"comment" ticket!