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

Re: [ns] Questions about TCP



To answer my own question:

there is the bound variable cwnd_, so with a command like

Agent/TCP instproc done {} {
#suppose sink_ was set after linking source and sink
$self instvar sink_
set sink [$self set sink_]
set tmp [$self set cwnd_]
$sink reset
$self reset
$self set cwnd_ $tmp
}

the current congestion window is retained.

But it is retained only for 2*current rtt. If next send comes after this
time, the cwnd_ starts from 1. Any ideas to set this timeout?

However the first packet in the next transmission is still marked as
retransmission, with flag ---A--- in trace file.

Thanking in advance

Nikos

"Nikolaos Katsarakis Austauschstud. (M. Schweigel)" wrote:

> Dear ns-users
>
> I have been using a TCP/Reno agent in my simulations in ns2.1b7a.
>
> In the done() callback, I reset the TCP source and sink. But then the
> next packet sent by the TCP Agent is marked in the ns trace file with
> the flags ---A---, meaning it is a retransmission, while it is the first
> packet of the new data to be sent. Shouldn't it just be normally marked
> like ------- ?
>
> Second, is there any way to get the current size of congestion window? I
> know I can trace it in a separate file, but I need it during the
> simulation, in order to set the initial window of an agent to this value
> after reset. In case you are wondering why I am doing the reset, it is
> only in order for the done() callback to be activated again. Is there
> maybe a better way to re-enable the calling of done() ?
>
> Thank you very much
>
> Nikos