Traceroute to Graphviz

From Federal Burro of Information
Revision as of 13:27, 16 January 2009 by David (talk | contribs) (New page: Traceroute from various places to your destination, dump the resu;ts to a file. then awk it up yo! <pre> awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

Traceroute from various places to your destination, dump the resu;ts to a file.

then awk it up yo!

awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"red\"];"}    ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"green\"];"}  ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"blue\"];"}   ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"black\"];"}  ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"orange\"];"} ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"salmon\"];"} ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"yellow\"];"} ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"darkgreen\"];"} ; last=$3"\\n"$2}' trace1.out
awk '{if ( length(last) > 0 && ( $2 != "*" ) ) {print "\"" last "\"->\"" $3"\\n"$2"\" [ color=\"thistle2\"];"} ; last=$3"\\n"$2}' trace1.out

Examples soon.

(all the examples I have , have delicate data in them)