Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to turn off NAK? #1960

Closed
toilandmoil opened this issue Apr 20, 2021 · 8 comments
Closed

How to turn off NAK? #1960

toilandmoil opened this issue Apr 20, 2021 · 8 comments
Assignees
Labels
Type: Question Questions or things that require clarification

Comments

@toilandmoil
Copy link

I use srt_setsockopt function sets SRTO_NAKREPORT option to false at the sender and receiver

Through Wireshark packet capture, it is found that the receiver will still send NAK packets to indicate the loss of packets.

@toilandmoil toilandmoil added the Type: Question Questions or things that require clarification label Apr 20, 2021
@ethouris
Copy link
Collaborator

ethouris commented Apr 20, 2021

"NAKREPORT" name is kinda misleading. This concerns only the "periodic NAK reports", that is, repeated LOSSREPORT in case when in a given expected time after previous LOSSREPORT the retransmission didn't happen.

For turning off LOSSREPORT sending completely, even this first time reported on loss detection, there's no option and this cannot be turned off. That is, it may be turned off if you turn on the packet filter and use FEC, in this case you have an option to either use ARQ (that is, reporting losses by LOSSREPORT) or not.

@maxsharabayko
Copy link
Collaborator

Further reading on types of NAK reports (loss-triggered and periodic) in SRT:
SRT RFC Section 4.8.2. Packet Retransmission (NAKs)

@toilandmoil
Copy link
Author

"NAKREPORT" name is kinda misleading. This concerns only the "periodic NAK reports", that is, repeated LOSSREPORT in case when in a given expected time after previous LOSSREPORT the retransmission didn't happen.

For turning off LOSSREPORT sending completely, even this first time reported on loss detection, there's no option and this cannot be turned off. That is, it may be turned off if you turn on the packet filter and use FEC, in this case you have an option to either use ARQ (that is, reporting losses by LOSSREPORT) or not.

Think you very much. Indeed, the NAK message can be closed by setting FEC.

@mbakholdina mbakholdina self-assigned this Apr 21, 2021
@maxsharabayko
Copy link
Collaborator

maxsharabayko commented May 18, 2021

One more way to indirectly disable retransmissions is to set msgttl to some low value (e.g. RTT/2 or 1ms).
In this case, the receiver will send a loss report, but the sender will not retransmit a packet, but send a drop request instead.

See msgttl in SRT_MSGCTRL.
Message Drop Request control packet (SRT RFC).

@yankee624
Copy link

@maxsharabayko Hi, I ran into a similar question.
Do you mean that I should add an SRT_MSGCTRL argument (with small msgttl value) to every srt_sendmsg2 call?

Also, is there any update in how to disable retransmission?

Thanks in advance!

@maxsharabayko
Copy link
Collaborator

@yankee624
With PR #2714 you could set SRTO_MAXREXMITBW to 0 to completely disable retransmissions.

@jeandube
Copy link
Collaborator

@yankee624 With PR #2714 you could set SRTO_MAXREXMITBW to 0 to completely disable retransmissions.

@maxsharabayko Does this mean that SRTO_MAXREXMITBW is not a sender-only option?

@maxsharabayko
Copy link
Collaborator

Sorry, you are right. That would be on the sender side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Question Questions or things that require clarification
Projects
None yet
Development

No branches or pull requests

6 participants