[ns] Problem

bouallegue bouallegue@iuplo.univ-ubs.fr
Mon, 22 Oct 2001 18:14:56 +0100


This is a multi-part message in MIME format.

------=_NextPart_000_0010_01C15B25.73F88930
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Dear all,=20
I am using the MPLS simulator for ns-2.1b8a-win (win NT).
I'm trying to run the essai.tcl but I 'm getting the following errors. I =
used exactly the same code from tutorial, it's not running. The errors =
that I'm getting are :

  (_o3 cmd line 1)
    invoked from within
"_o3 cmd MPLSnode"
    invoked from within
"catch "$self cmd $args" ret"
    (procedure "_o3" line 2)
    (SplitObject unknown line 2)
    invoked from within
"$ns MPLSnode"
        invoked from within
"set LSR2 [$ns MPLSnode]"
(file "essai.tcl" line 18.
Someone who know this problem,
Please help me. Thanx.

Bouallegue.

**********************************************************************
                 ESSAI.TCL
***********************************************************************
set ns [new Simulator]
set nf [open test-mpls.nam w]
$ns namtrace-all $nf
proc finish {} {
global ns nf
$ns flush-trace
close $nf
#exec nam test-mpls.nam &
exit 0
}
#
# make nodes & MPLSnodes
#
set Node0 [$ns node]
set Node1 [$ns node]
set LSR2 [$ns MPLSnode]
set LSR3 [$ns MPLSnode]
set LSR4 [$ns MPLSnode]
set LSR5 [$ns MPLSnode]
set LSR6 [$ns MPLSnode]
set LSR7 [$ns MPLSnode]
set LSR8 [$ns MPLSnode]
set Node9 [$ns node]
set Node10 [$ns node]
$ns duplex-link $Node0 $Node1 1Mb 10ms DropTail
$ns duplex-link $Node1 $Node9 1Mb 10ms DropTail
$ns duplex-link $Node9 $Node10 1Mb 10ms DropTail
#Create a Null agent (a traffic sink) and attach it to node node10
set sink0 [new Agent/LossMonitor]
$ns attach-agent $Node10 $sink0
######Create a UDP agent and attach it to node node0
set udp1 [new Agent/UDP]
$ns attach-agent $Node0 $udp1
# Create a CBR traffic source and attach it to udp1
set cbr1 [new Application/Traffic/CBR]
$cbr1 set packetSize_ 500
$cbr1 set interval_ 0.005
$cbr1 attach-agent $udp1
$ns connect $udp1 $sink0
$ns at 10.0 "$cbr1 start"
$ns at 50.0 "$cbr1 stop"
$ns at 30.0 "finish"
$ns run




------=_NextPart_000_0010_01C15B25.73F88930
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Diso-8859-1" =
http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.2314.1000" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Dear all, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I am using the MPLS simulator for =
ns-2.1b8a-win=20
(win NT).</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I'm trying to run the essai.tcl but I =
'm getting=20
the following errors. I used exactly the same code from tutorial, it's =
not=20
running. The errors that I'm getting are :<BR><BR>&nbsp; (_o3 cmd line=20
1)<BR>&nbsp;&nbsp;&nbsp; invoked from within<BR>"_o3 cmd=20
MPLSnode"<BR>&nbsp;&nbsp;&nbsp; invoked from within<BR>"catch "$self cmd =
$args"=20
ret"<BR>&nbsp;&nbsp;&nbsp; (procedure "_o3" line =
2)<BR>&nbsp;&nbsp;&nbsp;=20
(SplitObject unknown line 2)<BR>&nbsp;&nbsp;&nbsp; invoked from =
within<BR>"$ns=20
MPLSnode"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; invoked from=20
within<BR>"set LSR2 [$ns MPLSnode]"</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>(file "essai.tcl" line 18.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Someone who know this =
problem,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Please help me.=20
Thanx.<BR><BR>Bouallegue.<BR></DIV></FONT>
<DIV><FONT face=3DArial=20
size=3D2>****************************************************************=
******</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;=20
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ESSAI.TCL</FONT></DIV>
<DIV><FONT face=3DArial=20
size=3D2>****************************************************************=
*******</FONT></DIV><FONT=20
size=3D2><FONT size=3D2>
<DIV><FONT face=3DArial>set ns [new Simulator]</FONT></DIV>
<DIV><FONT face=3DArial>set nf [open test-mpls.nam w]</FONT></DIV>
<DIV><FONT face=3DArial>$ns namtrace-all $nf</FONT></DIV>
<DIV><FONT face=3DArial>proc finish {} {</FONT></DIV>
<DIV><FONT face=3DArial>global ns nf</FONT></DIV>
<DIV><FONT face=3DArial>$ns flush-trace</FONT></DIV>
<DIV><FONT face=3DArial>close $nf</FONT></DIV>
<DIV><FONT face=3DArial>#exec nam test-mpls.nam &amp;</FONT></DIV>
<DIV><FONT face=3DArial>exit 0</FONT></DIV>
<DIV><FONT face=3DArial>}</FONT></DIV>
<DIV><FONT face=3DArial>#</FONT></DIV>
<DIV><FONT face=3DArial># make nodes &amp; MPLSnodes</FONT></DIV>
<DIV><FONT face=3DArial>#</FONT></DIV>
<DIV><FONT face=3DArial>set Node0 [$ns node]</FONT></DIV>
<DIV><FONT face=3DArial>set Node1 [$ns node]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR2 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR3 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR4 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR5 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR6 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR7 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set LSR8 [$ns MPLSnode]</FONT></DIV>
<DIV><FONT face=3DArial>set Node9 [$ns node]</FONT></DIV>
<DIV><FONT face=3DArial>set Node10 [$ns node]</FONT></DIV>
<DIV><FONT face=3DArial>$ns duplex-link $Node0 $Node1 1Mb 10ms=20
DropTail</FONT></DIV>
<DIV><FONT face=3DArial>$ns duplex-link $Node1 $Node9 1Mb 10ms=20
DropTail</FONT></DIV>
<DIV><FONT face=3DArial>$ns duplex-link $Node9 $Node10 1Mb 10ms=20
DropTail</FONT></DIV>
<DIV><FONT face=3DArial>#Create a Null agent (a traffic sink) and attach =
it to=20
node node10</FONT></DIV>
<DIV><FONT face=3DArial>set sink0 [new Agent/LossMonitor]</FONT></DIV>
<DIV><FONT face=3DArial>$ns attach-agent $Node10 $sink0</FONT></DIV>
<DIV><FONT face=3DArial>######Create a UDP agent and attach it to node=20
node0</FONT></DIV>
<DIV><FONT face=3DArial>set udp1 [new Agent/UDP]</FONT></DIV>
<DIV><FONT face=3DArial>$ns attach-agent $Node0 $udp1</FONT></DIV>
<DIV><FONT face=3DArial># Create a CBR traffic source and attach it to=20
udp1</FONT></DIV>
<DIV><FONT face=3DArial>set cbr1 [new =
Application/Traffic/CBR]</FONT></DIV>
<DIV><FONT face=3DArial>$cbr1 set packetSize_ 500</FONT></DIV>
<DIV><FONT face=3DArial>$cbr1 set interval_ 0.005</FONT></DIV>
<DIV><FONT face=3DArial>$cbr1 attach-agent $udp1</FONT></DIV>
<DIV><FONT face=3DArial>$ns connect $udp1 $sink0</FONT></DIV>
<DIV><FONT face=3DArial>$ns at 10.0 "$cbr1 start"</FONT></DIV>
<DIV><FONT face=3DArial>$ns at 50.0 "$cbr1 stop"</FONT></DIV>
<DIV><FONT face=3DArial>$ns at 30.0 "finish"</FONT></DIV>
<DIV><FONT face=3DArial>$ns run</FONT></DIV>
<DIV></FONT></FONT>&nbsp;</DIV>
<DIV><BR>&nbsp;</DIV></BODY></HTML>

------=_NextPart_000_0010_01C15B25.73F88930--