Trace Format


NS2 New Trace format: NS2 Manual http://www.isi.edu/nsnam/ns/doc/node186.html

http://nsnam.isi.edu/nsnam/index.php/NS-2_Trace_Formats#New_Wireless_Trace_Formats

 New Wireless Trace Formats

This information comes from "The ns Manual" (http://www.isi.edu/nsnam/ns/doc/) "Mobile Networking in ns: Revised format for wireless traces" chapter, and the "trace/cmu-trace.cc" file. Similar to the old format, in the new format wireless traces begin with one of four characters. This is followed by flag/value pairs similar to NAM traces. The first letter of flags with two letters designates the flag type:

  • N: Node Property
  • I: IP Level Packet Information
  • H: Next Hop Information
  • M: MAC Level Packet Information
  • P: Packet Specific Information
Event Abbreviation Flag Type Value
Wireless Event s: Send
r: Receive
d: Drop
f: Forward
-t double Time (* For Global Setting)
-Ni int Node ID
-Nx double Node X Coordinate
-Ny double Node Y Coordinate
-Nz double Node Z Coordinate
-Ne double Node Energy Level
-Nl string Network trace Level (AGT, RTR, MAC, etc.)
-Nw string Drop Reason
-Hs int Hop source node ID
-Hd int Hop destination Node ID, -1, -2
-Ma hexadecimalDuration
-Ms hexadecimalSource Ethernet Address
-Md hexadecimalDestination Ethernet Address
-Mt hexadecimalEthernet Type
-P string Packet Type (arp, dsr, imep, tora, etc.)
-Pn string Packet Type (cbr, tcp)

Note that the value for the -Hd flag may be -1 or -2. -1 means that the packet is a broadcast packet, and -2 means that the destination node has not been set. -2 is typically seen for packets that are passed between the agent (-Nl AGT) and routing (-Nl RTR) levels.

Depending on the packet type, the following flags may be used:

Event Flag Type Value
ARP Trace -Po string Request or Reply
-Pmsint Source MAC Address
-Ps int Source Address
-Pmdint Destination MAC Address
-Pd int Destination Address
DSR Trace -Ph int Number Of Nodes Traversed
-Pq int Routing Request Flag
-Ps int Route Request Sequence Number
-Pp int Routing Reply Flag
-Pn int Route Request Sequence Number
-Pl int Reply Length
-Pe int->intSource->Destination Of Source Routing
-Pw int Error Report Flag (?)
-Pm int Number Of Errors
-Pc int Report To Whom
-Pb int->intLink Error From Link A to Link B
AODV Trace -Pt hexadecimalType
-Ph int Hop Count
-Pb int Broadcast ID
-Pd int Destination
-Pdsint Destination Sequence Number
-Ps int Source
-Pssint Source Sequence Number
-Pl double Lifetime
-Pc string Operation (REQUEST, REPLY, ERROR, HELLO)
TORA Trace -Pt hexadecimalType
-Pd int Destination
-Pa double Time
-Po int Creator ID
-Pr int R
-Pe int Delta
-Pi int ID
-Pc string Operation (QUERY, UPDATE, CLEAR)
IP Trace -Is int.int Source Address And Port
-Id int.int Destination Address And Port
-It string Packet Type
-Il int Packet Size
-If int Flow ID
-Ii int Unique ID
-Iv int TTL Value
TCP Trace -Ps int Sequence Number
-Pa int Acknowledgment Number
-Pf int Number Of Times Packet Was Forwarded
-Po int Optimal Number Of Forwards
CBR Trace -Pi int Sequence Number
-Pf int Number Of Times Packet Was Forwarded
-Po int Optimal Number Of Forwards
IMEP Trace -Pa char Acknowledgment Flag
-Ph char Hello Flag
-Po char Object Flag
-Pl hexadecimalLength

AODV Trace Formats

AODV traces begin with an "A", followed by the AODV trace. This information comes from the "aodv/aodv_logs.cc" source file.

Event Abbreviation Type Value
Delete Link A %.9f _%d_ deleting LL hop to %d (delete %d is %s)
double Time
int Index
int Destination
int Deleted Link Count
string Link State (VALID, INVALID)
Broken Link A %.9f _%d_ LL unable to deliver packet %d to %d (%d) (reason = %d, ifqlen = %d)
double Time
int Index
int Unique Packet ID
int Next Hop
int Broken Link Count
int Transmit Reason
int Queue Length
Keeping Bad Link A %.9f _%d_ keeping LL hop to %d (keep %d is %s)
double Time
int Index
int Destination
int Kept Bad Link Count
string Link State (VALID, INVALID)

DSDV Trace Formats

DSDV traces begin with a "V", followed by additional characters to indicate the exact DSDV trace. This information comes from the "dsdv/dsdv.cc" source file.

Event Abbreviation Type Value
Trace Packet VPU
VTU
%.5f _%d_ [%d] (%d,%d,%d) ...
double Time
int Reporting Address
int Count
int Destination
int Distance (Metric)
int Sequence Number
Periodic Callback VPC %.5f _%d_
double Time
int Reporting Address
Timeout VTO %.5f _%d_ %d->%d
double Time
int Reporting Address
int Reporting Address (Should be Source???)
int Routing Table Destination
%.5f _%d_ marking %d
double Time
int Reporting Address
int Routing Table Destination
Lost Link VLL %.8f %d->%d lost at %d
double Time
int Source
int Destination
int Reporting Address
Lost Packet VLP %.5f %d:%d->%d:%d lost at %d [hop %d]
double Time
int Source
int Source Port
int Destination
int Destination Port
int Reporting Address
int Routing Table Destination
Change Table VCT %.5f _%d_ %d
double Time
int Reporting Address
int Routing Table Destination
Weighted Settling Time VWST %.12lf frm %d to %d wst %.12lf nxthp %d [of %d]
double Time
int Reporting Address
int Routing Table Destination
double Weighted Settling Time
int Next Hop
int Distance (Metric)
Update Route VSD
VSU
%.5f _%d_ (%d,%d->%d,%d->%d,%d->%d,%f)
double Time
int Reporting Address
int Old Destination
int Old Distance (Metric) or -1
int New Distance (Metric)
int Old Sequence Number or -1
int New Sequence Number
int Old Hop or -1
int New Hop
double When Okay To Advertise This Route
Queue Packet VBP %.5f _%d_ %d:%d -> %d:%d
double Time
int Reporting Address
int Source Address
int Source Port
int Destination Address
int Destination Port
Routing Packets Outside Domain VFP %.5f _%d_ %d:%d -> %d:%d
double Time
int Reporting Address
int Source Address
int Source Port
int Destination Address
int Destination Port
Table Dump VTD %.5f %d:%d
double Time
int Reporting Address
int Source Address
int Source Port

DSR Trace Formats

DSR traces begin with an "S", which may be followed by additional characters to indicate the exact DSR trace. Each trace has one or more formats. This information comes from the "dsr/dsragent.cc", "dsr/linkcache.cc", "dsr/mobicache.cc", "dsr/routecache.cc", and "dsr/simplecache.cc" source files.

Event Abbreviation Type Value
Send S %.9f _%s_ originating %s -> %s
double Time
string ID
string Source
string Destination
Have A Route S$hit %.5f _%s_ %s -> %s %s
double Time
string ID
string Source
string Destination
string Route
Don't Have A Route S$miss %.5f _%s_ %s -> %s
double Time
string ID
string ID (Should be Source???)
string Destination
Configuration parameters. All strings are either "on" or "off" Sconfig %.5f tap: %s snoop: rts? %s errs? %s
double Time
string Use TAP
string Snoop Source Routes
string Snoop Forwarded Errors
%.5f salvage: %s !bd replies? %s
double Time
string Salvage With Cache
string Don't Salvage Bad Replies
%.5f grat error: %s grat reply: %s
double Time
string Propagate Last Error
string Send Grat Replies
%.5f $reply for props: %s ring 0 search: %s
double Time
string Reply From Cache On Propagating
string Ring Zero Search
%.5f using MOBICACHE
double Time
%.5f using LINKCACHE
double Time
Debug message Sdebug %.5f _%s_ stuck into send buff %s -> %s
double Time
string ID
string Source
string Destination
%.5f _%s_ checking for route for dst %s
double Time
string ID
string Destination
%.5f _%s_ sendbuf pkt to %s liberated by handlePktWOSR
double Time
string ID
string Destination
%.9f _%s_ splitting %s to %s
double Time
string ID
string Route
string Route Copy
%.9f _%s_ liberated from sendbuf %s->%s %s
double Time
string ID
string Source
string Destination
string Route
%.5f _%s_ unwrapping nested route error
double Time
string ID
_%s_ tap saw error %d
string ID
int Header UID
_%s_ tap saw route reply %d  %s
string ID
int Header UID
string Reply Path
_%s_ tap saw route use %d %s
string ID
int Header UID
string Route
%s consider grat arp for %s
string ID
string Route
_%s_ not bothering to send route error to ourselves
string ID
%.5f _%s_ sending into dead-link (nest %d) tell %d %d -> %d
double Time
string ID
int Number Of Route Errors
int Report To Address
int From Address
int To Address
%.9f _%s_ adding %s [%d %.9f] ...
double Time
string ID
string Path
int Link Type
double Time Added
%.9f _%s_ checking %s [%d %.9f] ...
double Time
string ID
string Path
int Link Type
double Time Added
%.9f _%s_ freshening %s->%s to %d %.9f
double Time
string ID
string Path
string Next Path
int Link Type
double Time Added
Errors SDFU %.5f _%s_ dumping maximally nested error %s %d -> %d
double Time
string ID
string Tell ID
int From
int To
ran off the end of a source route
non route containing packet given to acceptRouteReply
route error beyond end of source route????
route error forwarding route request????
Flowstate SFs %.9f _%s_ %d [%s -> %s] %d(%d) to %d
double Time
string ID
int Header UID
string Source
string Destination
int Flow ID
int Flow Header
int Next Hop
Established Flowstate SFESTs %.9f _%s_ %d [%s -> %s] %d(%d) to %d %s
double Time
string ID
int Header UID
string Source
string Destination
int Flow ID
int Flow Header
int Next Hop
string Addresses
Flow ARS SFARS %.9f _%s_ %d [%s -> %s] %d %d
double Time
string ID
int Header ID
string Source
string Destination
int Flow ID
int Amt
Flow Error SFEr %.9f _%s_ from %d re %d : %d [%d]
double Time
string ID
int Source
int Flow Destination
int Flow ID (-1 For Default)
int Count (-1 For No Flow Index)
Unknown Flow SFErr %.5f _%s_ %d -> %d : %d
double Time
string ID
int Source
int Flow Destination
int Flow ID
Flow Forward SFf %.9f _%s_ %d [%s -> %s] %d to %d
double Time
string ID
int Header ID
string Source
string Destination
int Flow ID
int Next Hop
Interface Queue SIFQ %.5f _%s_ len %d
double Time
string ID
int Queue Length
Send Out Packet With Route SO %.9f _%s_ originating %s %s
double Time
string ID
string Protocol Name
string Route
Route Cache - Summary SRC %.9f _%s_ cache-summary %d %d %d %d | %d %.9f %d %d | %d %d %d %d %d | %d %d %d %d %d | %d %d %d %d %d %d %.9f
%.9f _%s_ cache-summary %d %d %d %d | %d %.9f %d %d | %d %d %d %d %d | %d %d %d %d %d | %d %d %d %d %d %d
double Time
string ID
int Route Count
int Route Bad Count
int Subroute Count
int Subroute Bad Count
int Link Bad Count
double Average Bad Time Per Link
int Link Bad Tested
int Link Good Tested
int Route Add Count
int Route Add Bad Count
int Subroute Add Count
int Subroute Add Bad Count
int Link Add Tested
int Route Notice Count
int Route Notice Bad Count
int Subroute Notice Count
int Subroute Notice Bad Count
int Link Notice Tested
int Route Find Count
int Route Find For Me
int Route Find Bad Count
int Route Find Miss Count
int Subroute Find Count
int Subroute Find Bad Count
double Link Good Time (Only In First Format)
Route Cache - Node Cache Dump (only with patch) SRC %.9f _%s_ cache-dump p %d %d | %d %d %d %s | ... | s %d %d | %d %d %d %s | ... |
double Time
int Source Node
int Primary Cache Current Size
int Primary Cache Maximum Size
int Cache Entry Index
int Cache Entry Length
int Cache Entry Address
string Cache Entry Dump
int Secondary Cache Current Size
int Secondary Cache Maximum Size
int Cache Entry Index
int Cache Entry Length
int Cache Entry Address
string Cache Entry Dump
Route Cache - Node Cache Dump, No Primary Cache (only with patch) SRC %.9f _%s_ cache-dump s %d %d | %d %d %d %s | ... |
double Time
int Source Node
int Secondary Cache Current Size
int Secondary Cache Maximum Size
int Cache Entry Index
int Cache Entry Length
int Cache Entry Address
string Cache Entry Dump
Route Cache - Find Route Cache Hit SRC %.9f _%s_ $hit for %s in %s %s
double Time
string ID
string Destination
string Primary Or Secondary Cache
string Route
Route Cache - Find Route Cache Miss SRC %.9f _%s_ find-route [%d] %s->%s miss %d %.9f
double Time
string ID
int Hardcoded Zero
string ID (Should Be Source???)
string Destination
int Hardcoded Zero
double Hardcoded Zero
Route Cache - New Route Contains Cached Route SRC %.9f _%s_ %s suffix-rule (len %d/%d) %s
double Time
string ID
string Cache Name (primary, secondary)
int Path Length
int Route Length
string Route Dump
Route Cache - New Route Contained In Cache SRC %.9f _%s_ %s prefix-rule (len %d/%d) %s
double Time
string ID
string Cache Name (primary, secondary)
int Path Length
int Route Length
string Route Dump
Route Cache - Discard Route SRC %.9f _%s_ %s evicting %s
double Time
string ID
string Name
string Dumped Route
Route Cache - Discard Route SRC %.9f _%s_ evicting %d %d %s
double Time
string ID
int Route Length -1
int Number Of Bad Routes
string Name
Route Cache - Add Route After Dumping Route SRC %.9f _%s_ while adding %s
double Time
string ID
string Name
string Added Path
Route Cache - Truncating Route To Remove Dead Link SRC %.9f _%s_ %s truncating %s %s
double Time
string ID
string Name
string Route
string Owner
Route Cache - Truncated Or Removed Route With Dead Link SRC %.9f _%s_ to %s %s
double Time
string ID
string Route
string Owner
Route Cache - Dead Link SRC %.9f _%s_ dead link %s->%s
double Time
string ID
string From
string To
Route Cache - Dead Link SRC %.9f _%s_ %s [%d %d] %s->%s dead %d %.9f
double Time
string ID
string Operation In Progress (add-route, notice-route, find-route, dead-link, evicting-route, check-cache)
int Route Length
int Route Index
string Route
string Next Route
int Link Type
double Time Added
Route Cache - Resurrected Link SRC %.9f _%s_ resurrected-link [%d %d] %s->%s dead %d %.9f
double Time
string ID
int Route Length
int Route Index
string Route
string Next Route
int Link Type
double Time Added
Route Cache - Add Route SRC %.9f _%s_ adding rt %s from %s
double Time
string ID
string Route
string From
Route Cache - Dump Dijkstra SRC %.9f _%s_ dijkstra *%d* %d,%d,%d ...
double Time
string ID
int Destination
int Index
int Estimated Shortest Path To Vertex (d)
int Predecessors For Vertex (pi)
Route Cache - Dump Link SRC %.9f _%s_ dump-link %d->%d, ...
double Time
string ID
int Index
int Link Destination
Route Cache - Cache Expire Bits SRC %.9f _%s_ cache-expire-bits %d %d %d %d
double Time
string ID
int Expire Stats 0
int Expire Stats 1
int Expire Stats 2
int Expire Stats 3
Route Request/Reply SRR %.5f _%s_ dropped %s #%d (ignored)
double Time
string ID
string Source
int Route Request Sequence
%.9f _%s_ discarding %s #%d (ifq length %d)
double Time
string ID
string Source
int Route Request Sequence
int Queue Length
%.9f _%s_ discarding %s #%d (free air time %f)
double Time
string ID
string Source
int Route Request Sequence
int Free Air Time
%.5f _%s_ dropped %s #%d (prop limit exceeded)
double Time
string ID
string Source
int Route Request Sequence
%.5f _%s_ dropped %s #%d (SR full)
double Time
string ID
string Source
int Route Request Sequence
%.5f _%s_ rebroadcast %s #%d ->%s %s
double Time
string ID
string Source
int Route Request Sequence
string Destination
string Route
%.9f _%s_ cache-reply-sent %s -> %s #%d (len %d) %s
double Time
string ID
string Source
string Destination
int Request Sequence Number
int Route Length
string Route
%.5f _%s_ RR-not-sent %s -> %s
double Time
string ID
string Route Request Source
string Route Request Destination
%.5f _%s_ new-request %d %s #%d -> %s
double Time
string ID
int Maximum Propagation
string Source
int Route Request Sequence
string Destination
%.9f _%s_ reply-sent %s -> %s #%d (len %d) %s
double Time
string ID
string Source
string Destination
int Route Request Sequence
int Route Length
string Route
%.9f _%s_ reply-received %d from %s  %s #%d -> %s %s
double Time
string ID
int Good Reply (0, 1)
string Source
string First Reply Route
int Route Request Sequence
string Last Reply Route
string Reply Route
%.9f _%s_ dead-link tell %d  %d -> %d
double Time
string ID
int Report To Address
int From Address
int To Address
%.9f _%s_ gratuitous-reply-sent %s -> %s (len %d) %s
double Time
string ID
string Source
string Destination
int Route Length
string Route
%.5f _%s_ --- %d dropping bad-reply %s -> %s
double Time
string ID
int Header UID
string Source
string Destination
Salvage Ssalv %.5f _%s_ salvaging %s -> %s --- %d with %s
double Time
string ID
string Source
string Destination
int Header UID
string Route
%.5f _%s_ adding to SB --- %d %s -> %s [%d]
double Time
string ID
int Header UID
string Source
string Destination
int Salvaged
%.5f _%s_ dropping --- %d %s -> %s [%d]
double Time
string ID
int Header UID
string Source
string Destination
int Salvaged
Packet dropped by send buffer in DSR agent Ssb %.5f _%s_ dropped %s -> %s
double Time
string ID
string Source
string Destination
Send Failure SSendFailure %.9f _%s_ %d %d %d:%d %d:%d %s->%s %d %d %d %d %s
double Time
string ID
int Header UID
int Protocol Type
int Source
int Source Port
int Destination
int Destination Port
string From ID
string To ID
int Hops: From -> To
int Hops: Source -> Destination
int Hops: From -> Destination
int Number Of Addresses
string Header
Transmit Failed SxmitFailed %.5f _%s_  %d->%d god okays #%d
double Time
string ID
int From ID
int To ID
int Number of Wrong Link Errors
Maximally Nested Flow Error SYFU %.5f _%s_ dumping maximally nested Flow error %d -> %d
double Time
string ID
int Source
int Flow Destination
Attempted To Add Bad Route To Cache %.9f _%s_ adding bad route to cache %s %s
double Time
string ID
string Source
string Route

TORA Trace Formats

TORA traces begin with a "T", followed by one of several formats. This information comes from the "tora/tora.cc", "tora/tora_api.cc", and "tora/tora_io.cc" source files.

Event Abbreviation Type Value
TORA Event T %.9f _%d_ tora sendQRY %d
double Time
int Address
int ID
%.9f _%d_ QRY %d for %d (rtreq set)
double Time
int Address
int TORA Destination Index
int Index
%.9f _%d_ tora enq %d->%d
double Time
int Address
int Source
int Destination
%.9f _%d_ received `UPD` from non-neighbor %d
double Time
int Address
int Source
%.9f _%d_ received `CLR` from non-neighbor %d
double Time
int Address
int Source

Mobile node movement and energy trace formats

Mobile node traces begin with "M" or "N". This information comes from the "common/mobilenode.cc" source file.

Event Abbreviation Type Value
Mobile Node Movement M %.5f %d (%.2f, %.2f, %.2f), (%.2f, %.2f), %.2f
double Time
int Address (Node ID?)
double X Coordinate
double Y Coordinate
double Z Coordinate
double Destination X Coordinate
double Destination Y Coordinate
double Movement Speed
Mobile Node Energy N -t %f -n %d -e %f
double Time
int Address (Node ID?)
double Energy



























Comments