[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: question about token bucket filter
tbf inherits from connector, basically you could insert it anywhere, for example
see how they insert connector objects for tracing in ns-link.tcl.
> X-Authentication-Warning: mash.CS.Berkeley.EDU: majrdomo set sender to
[email protected] using -f
> To: Poyuen Cheng <[email protected]>
> Cc: "'[email protected]'" <[email protected]>,
[email protected]
> Subject: Re: question about token bucket filter
> Mime-Version: 1.0
> Date: Thu, 11 Nov 1999 18:47:08 -0500
> From: Lee Breslau <[email protected]>
>
>
> The reason this isn't doing what you want is because the TBF you
> created at n1 does not receive the packets generated at n0.
> The TBF at n1 sits between the new agent, aa, and node n1. Any
> packets sourced by aa will pass through the TBF. However, the
> packets sourced by agent 'a' are forwarded from n0 to n1. They
> pass through the node object, n1, and are forwarded to n2. They
> do not reach the TBF.
>
> Accomplishing what you want would require inserting the TBF into
> the node object (instead of merely inserting the TBF between an agent
> and its attached node). This is certainly feasible, but I don't
> think there are any functions currently in ns to do this (but I
> may be wrong on that account).
>
> Lee
>
>
> >
> > Hi,
> >
> > In the token bucket example /tcl/ex/test-tbf.tcl, the tbf is used as:
> >
> > set exp1 [new Application/Traffic/Exponential]
> > set a [new Agent/UDP]
> > $exp1 attach-agent $a
> > set tbf [new TBF]
> > $ns attach-tbf-agent $n0 $a $tbf
> >
> > Topology: n0----------n2
> >
> > i.e., The node 0 perform both traffic generation and tbf.
> >
> > Right now, I wish to sperate them into node0 and node1, where
> > node0 perform traffic generate and node1 perform tbf.
> >
> > Topology n0----n1-------n2
> >
> > set exp1 [new Application/Traffic/Exponential]
> > set a [new Agent/UDP]
> > $exp1 attach-agent $a
> > $ns attach-agent $n0 $a
> > set aa [new Agent/UDP]
> > set tbf [new TBF]
> > $ns attach-tbf-agent $n1 $aa $tbf
> >
> > With this way, the traffic shape is the same before n1 and after n1.
> > It seems that tbf applied in n1 is "transparent" to the traffic.
> >
> > Your help is very appreciated.
> >
> >
> > Po-Yuen Cheng
>
>
Tarik