Modify RTO and DupAcks threshold in TCP congestion control algorithm

69 views
Skip to first unread message

Tianfang Chang

unread,
Sep 13, 2023, 5:13:55 PM9/13/23
to ns-3-users
Hello all,

I find existing congestion control algorithms(CCA) in ns-3 are focusing on modifying m_cWnd and m_ssThresh which can be accessed with pointer of Ptr<TcpSocketState> tcb. However, when I want to realize CCA related to modifying RTO and action after receiving duplicate ACKs, there is no recommended function like a pointer to touch RTO and DupACK threshold. Do you have any suggestions about realizing CCA that needs change the members in tcp-socket-state? 

If we change them, it seems diffcult to test the fairness of co-exist with other CCA bacause we change the tcp-socket-base.

Best,
Tianfang

Tommaso Pecorella

unread,
Sep 13, 2023, 5:58:07 PM9/13/23
to ns-3-users
Nothing prevents you to add a setter... but RTO is not set by the CCA, it's estimated when you receive a packet.
You can, of course, use a different estimation method, but if your goal is a fair evaluation between two (or more) Congestion Control lags, both must use the same RTO estimation.

About DupAcks, I guess you're searching for "TcpTxBuffer::SetDupAckThresh(uint32_t dupAckThresh)"

Tianfang Chang

unread,
Sep 13, 2023, 6:37:16 PM9/13/23
to ns-3-...@googlegroups.com
Hello Tom,

Thank you for your response. Actually, I want to realize the TCP-PR (https://ieeexplore.ieee.org/document/1203469), an old CCA proposed in 2003.
It removes the following actions (mainly about fast retransmit) after receiving duplicate ACKs, just uses estimated/calculated RTO to detect packet loss. It's quite different from other CCAs with modifying cWnd and ssThresh, etc.
I am confused about how to realize it and test its co-existence with other CCA. Maybe I should add more set/calculation functions for RTO, and comment the code about actions after receiving duplicate ACKs roughly.
I am a fresh hand in ns-3 programming, thank you for your help.

Best regards,
Tianfang

Tommaso Pecorella <tomm...@gmail.com> 于2023年9月13日周三 14:58写道:
--
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
---
You received this message because you are subscribed to a topic in the Google Groups "ns-3-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ns-3-users/LjZ6CO2Kssc/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ns-3-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ns-3-users/bc7bf0af-1367-4553-bbca-f09d47745011n%40googlegroups.com.


--
Best,
Tianfang

Tommaso Pecorella

unread,
Sep 13, 2023, 6:57:29 PM9/13/23
to ns-3-users
This is an alternative link: https://www.eecis.udel.edu/~bohacek/Papers/366Bohacek.pdf

About how to code it, I can't really help - but from what I did read about TCP-PR, you could just forget about TcpSocketState and just calculate your own stuff by yourself. The only problem (if it's a problem) is to schedule a periodic function to decide when a packet is too old (and assume it's lost).
It's not hard at all, but how you implement it might make the simulation slow.

How to compare CCAs... simple: use them - no need to mix and match things. They're different, and you shall compare them in the same system without touching them.

Tianfang Chang

unread,
Sep 14, 2023, 12:06:15 PM9/14/23
to ns-3-...@googlegroups.com
Thank you for your generous reply, it's really helpful.

Best regards,
Tianfang

Tommaso Pecorella <tomm...@gmail.com> 于2023年9月13日周三 15:57写道:


--
Best,
Tianfang
Reply all
Reply to author
Forward
0 new messages