[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ns] queue management




Your $srcQueue and $destQueue should be the queue type,
i.e. the class name of the queue, instead of an instance 
of a queue type.

On Wed, May 16, 2001 at 10:20:10AM +0000, [email protected] wrote:
> 
> Hi,
> 
> My question concerns this topology
> #  
> #  
> #    Q_s --- Q_d --- Q_out
> #
> 
> And the source code is attached in a separate file (aa.tcl).
> 
> I am trying to create Queue objects  Queue/DropTail and to attach them to
> links like bellow 
> 
> set srcQueue [new Queue/DropTail]
> set destQueue [new Queue/DropTail]
> 
> # Links creation
> $ns duplex-link $Q_s $Q_d 4Mb 1ms $srcQueue 
> $ns duplex-link $Q_d $Q_out 0.90Mb 5ms $destQueue
> 
> But I have the following error :
> =====================================
> ns arrow 10 10 1000
> invalid command name "Queue/_o19"
>     while executing
> "Queue/_o19 create _o21 "
>     invoked from within
> "catch "$className create $o $args" msg"
>     (procedure "new" line 3)
>     invoked from within
> "new Queue/$qtype"
>     ("default" arm line 3)
>     invoked from within
> "switch -exact $qtype {
> ErrorModule {
> if { [llength $args] > 0 } {
> set q [eval new $qtype $args]
> } else {
> set q [new $qtype Fid]
> }
> }
> intserv {
> set qtyp..."
>     (procedure "_o3" line 10)
>     (Simulator simplex-link line 10)
>     invoked from within
> "_o3 simplex-link _o10 _o13 4Mb 1ms _o19"
>     ("eval" body line 1)
>     invoked from within
> "eval $self simplex-link $n1 $n2 $bw $delay $type $args"
>     (procedure "_o3" line 8)
>     (Simulator duplex-link line 8)
>     invoked from within
> "$ns duplex-link $Q_s $Q_d 4Mb 1ms $srcQueue "
>     (file "arrow" line 113)                          
> =====================================
> 
> My objectif is to access to the queue attached to a given link ($Q_d
> $Q_out) in order to stop sending 
> packets from Q_s depending in the state of this queue (for example when it
> is not full).
> 
> Is it the right way to do it ? 
> Thanks for your help.
> Ahmad.
> 
> 
> =============================================
> Ahmad BADRAH
> 
> Performance Modeling Architect
> e-mail : [email protected]
> phone  : +33 (0)4 92 94 48 18
> Tachys Technologies
> Les Algorithmes, ABS BP 29
> 06901 Sophia-Antipolis Cedex
> 
> http://www.tachys.com
> 
> 

--