Return-Path: lccheung@usc.edu
Delivery-Date: Thu Mar 15 00:43:40 2007
X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on merlot.usc.edu
X-Spam-Level: 
X-Spam-Status: No, score=-3.8 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 
	autolearn=ham version=3.1.3
Received: from msg-mx5.usc.edu (msg-mx5.usc.edu [128.125.137.10])
	by merlot.usc.edu (8.13.5/8.13.5) with ESMTP id l2F7he51024809
	for <cs551@merlot.usc.edu>; Thu, 15 Mar 2007 00:43:40 -0700
Received: from LesliePC ([71.130.127.95])
 by msg-mx5.usc.edu (Sun Java System Messaging Server 6.2-7.05 (built Sep  5
 2006)) with ESMTPSA id <0JEX00916PCQEL20@msg-mx5.usc.edu> for
 cs551@merlot.usc.edu; Thu, 15 Mar 2007 00:41:14 -0700 (PDT)
Date: Thu, 15 Mar 2007 00:41:11 -0700
From: Leslie Cheung <lccheung@usc.edu>
Subject: RE: cs551 nam file
In-reply-to: <92e7c4b70703142349t7f54e697n9355e2de565da9a5@mail.gmail.com>
Sender: lccheung@usc.edu
To: cs551@merlot.usc.edu
Message-id: <0JEX00917PCQEL20@msg-mx5.usc.edu>
MIME-version: 1.0
X-MIMEOLE: Produced By Microsoft MimeOLE V6.0.6000.16386
X-Mailer: Microsoft Office Outlook, Build 11.0.5510
Content-type: text/plain; charset=us-ascii
Content-transfer-encoding: 7bit
Thread-index: AcdmziE4zluO5WaAT9i8jpGKGqGVkQABPDsg

Someone wrote:

> Do you know a good tutorial on nam file construction?

I don't really have any tutorial on nam traces. One good starting point is
the "status.out" example in the spec. Let me elaborate on the example here.

V -t * -v 1.0a5

This first line is an initialization command. Just keep this as the first
line in your nam output.

n -t * -s 3 -c red -i black
n -t * -s 4 -c red -i black

Each of these lines creates a node. 
"n" means node. 
"-t *" indicates time. You can just keep it this way.
"-s 3" means source id. This should represent the well-known port of the
nodes. (You can assume all nodes run on nunki, and hence using port number
alone can identify a node.)
"-c red" means color of the node is red.
"-I black" means color of the label (port number) is black.


l -t * -s 3 -d 4 -c blue

This line creates a link.
"l" means link". 
"-t *" indicates time. 
"-s 3" means source id, and "-d 4" means destination id. In the context of
our project, since all we care is who is connected to who, it doesn't matter
which node is the source, and which node is the destination. So, "-s 3 -d 4"
is the same as "-s 4 -d 3". Again, you can use port number as id.
"c blue" means the color of the link is blue.


There is documentation on Nam traces in the Ns manual. You can go to
http://www.isi.edu/nsnam/ns/doc/index.html and search for "Nam Traces"
(Subsection 46).


--Leslie
