cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
6070
Views
5
Helpful
3
Replies

UDP VS Window Size

169.254.X.Y
Level 1
Level 1

For TCP communication, the sender and the receiver exchange their window size through 3 way handshake. But, for UDP communication, since it is not reliable, there is no ACK or window size. I am not sure, but probably the sender will fragment the data according to MTU in UDP communication. My question is what happen if the receiver's window size(not sure whether window size matters for UDP communication) or MTU size is smaller than the received packet size?   

1 Accepted Solution

Accepted Solutions

Peter Paluch
Cisco Employee
Cisco Employee

Hello,

For TCP communication, the sender and the receiver exchange their window size through 3 way handshake.

As we discussed in a different thread you have opened, receiver window size and MSS are two independent things. During the 3-way handshake, TCP endpoints advertise their MSS. However, the size of the receiver window of each TCP endpoint is indicated in each TCP header sent from that endpoint, not just during the 3-way handshake.

My question is what happen if the receiver's window size(not sure whether window size matters for UDP communication) or MTU size is smaller than the received packet size?

UDP does not have a concept window size whatsoever. However, if the endpoint where the UDP socket is listening received a packet larger than its MTU, the IP driver would declare this packet to be oversized, and would likely drop it - so the UDP driver would not even see the segment, as the IP packet containing that segment would be discarded.

Best regards,
Peter

View solution in original post

3 Replies 3

Peter Paluch
Cisco Employee
Cisco Employee

Hello,

For TCP communication, the sender and the receiver exchange their window size through 3 way handshake.

As we discussed in a different thread you have opened, receiver window size and MSS are two independent things. During the 3-way handshake, TCP endpoints advertise their MSS. However, the size of the receiver window of each TCP endpoint is indicated in each TCP header sent from that endpoint, not just during the 3-way handshake.

My question is what happen if the receiver's window size(not sure whether window size matters for UDP communication) or MTU size is smaller than the received packet size?

UDP does not have a concept window size whatsoever. However, if the endpoint where the UDP socket is listening received a packet larger than its MTU, the IP driver would declare this packet to be oversized, and would likely drop it - so the UDP driver would not even see the segment, as the IP packet containing that segment would be discarded.

Best regards,
Peter

Another Enlightenment :) Thank you very much!!!

Joseph W. Doherty
Hall of Fame
Hall of Fame
"My question is what happen if the receiver's window size(not sure whether window size matters for UDP communication) or MTU size is smaller than the received packet size? "

This cannot happen, as the IP receiver should be able to accept a full size IP packet (64 KB) regardless of MTU being used.

Generally, sending sources insure IP packets do not exceed their initial MTU, but along-the-way MTU might be less, causing IP fragmentation. Then received IP packets will need to be reassembled from received fragmented packets.

Although receiver should be able to deal with a max sized IP packet, a receiver's IP driver will likely have limitations on how much buffer space it has for reassembling IP packets or perhaps waiting for other parts of the system to take received IP packets off-its-hands.
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card