GetEstimate() of TCP rtt estimator returns strange values

44 views
Skip to first unread message

richard.wi...@gmail.com

unread,
Feb 19, 2019, 12:26:39 PM2/19/19
to ns-3-users
Hi all,

I have 3 parallel TCP connections between 2 nodes (T_entry and T_exit). Each connection is via a direct link with no nodes in between.

Since for understanding a bug often the goal/context is important: The goal is to evaluate an packet scheduling algorithm for adaptive mulitpath tunneling. Currently the subtunnels use TCP but I intend to switch to DCCP or construct something on top of UDP in the longterm. Anyway the algorithm needs the srtt estimations of the subtunnels transport protolcol
to make good decisions.

Calling
  m_sock->m_rtt->GetEstimate().GetSeconds();
with m_sock as the TCP socket returns the following values:

```
Srtt_Est of 0 :1.8e-08   
Srtt_Est of 1 :6.87936e+09
Srtt_Est of 2 :12.8849   
Srtt_Est of 0 :4.9e-08   
Srtt_Est of 1 :6.87936e+09
Srtt_Est of 2 :12.8849   
Srtt_Est of 0 :4.9e-08   
Srtt_Est of 1 :6.87936e+09
Srtt_Est of 2 :12.8849                                                                       
Srtt_Est of 0 :6.5e-08                                      
Srtt_Est of 1 :6.87936e+09                                       
Srtt_Est of 2 :12.8849                                       
Srtt_Est of 0 :3.3e-08
Srtt_Est of 1 :6.87936e+09
Srtt_Est of 2 :12.8849
```
Which I find strange given the use the following csma link settings for the 3 links:

  Config::SetDefault("ns3::CsmaChannel::Delay", TimeValue (NanoSeconds (6560)));
  tunnel_1_net_helper.SetChannelAttribute("DataRate", StringValue("16Mb/s") );
  tunnel_2_net_helper.SetChannelAttribute("DataRate", StringValue("50Mb/s") );
  tunnel_3_net_helper.SetChannelAttribute("DataRate", StringValue("32Mb/s") );

rtts should be somewhere around 2-3ms given processing delay, queueing delay, serialisation delay, etc.
I read the rtt Mean deviation class code but could not find any obvious error.

Any idea where I could look? Did I forget any attribute for CSMA or TCP? Should I use my own TCP estimator
object and feed it with values from the rtt trace source, instead of asking the one of TCP?

Thank you,
-- Richard

Richard Sailer

unread,
May 8, 2019, 9:43:12 PM5/8/19
to ns-3-users
Hi,
For anyone interested, I found the solution some time ago, it was nothing wrong with ns-3. Different parts of my simulation used different
header files, I had modified copy of a header in the waf build output directory, but not the corresponding one in src/, so the module used the old header for building it self
but other modules used the new one for linking. Therefore parts of the class/struct were at other memory addresses than the outside modules expected and they got garbage^^

So the lesson is if you really have to change api headers, change them in src/ and be very careful with it.

Thanks,
Richard
Reply all
Reply to author
Forward
0 new messages