The TCP Proxy Buffer
Hi,
First off all great article! However I still have some doubts how exactly flow of traffic from client is going on.
Let's assume we have fresh TCP connection between BIG-IP and backend server. To make things easier let's assume Slow Start is disabled.
My assumption of the process is:
BIG-IP sends SYN with window 64k (size of Receive Window in serverside profile)
Serwer sends packet with 1000B (after 3WHS finished)
BIG-IP passes data to clientside profile, it lands in Proxy Buffer
BIG-IP transfers data from Proxy Buffer to Send Buffer - Proxy Buffer is empty
BIG-IP sends data to client, data is still in Send Buffer as client has to ACK it, so Send Buffer capacity is decreased by 1000B, let's assume Nagle is enabled so BIG-IP will not send more data until ACK from client arrives
BIG-IP is not changing window size on serverside - there is plenty of space in Proxy Buffer
Now there is a question what happens when next 1000B arrives from server?
It's placed in Proxy Buffer?
Is it passed to Send Buffer, or because of Nagle BIG-IP knows that if there is data in Send Buffer it will not be able to send more to the client, so it keeps data in Proxy Buffer?
Then assuming we still have no ACK from client process is repeated until Proxy Buffer High is reached
Will BIG-IP start to reduce window size according to decreasing capacity of Proxy Buffer?
At this time BIG-IP is sending ACK on serverside with zero window size
It will continue until Send Buffer will be empty (because of Nagle)
Then data is passed from Proxy Buffer to Send Buffer until Proxy Buffer Low is reached.
At this point BIG-IP sends ACK with non zero window size - what will be this window? Difference between Proxy Buffer High and amount of bytes currently kept in Proxy Buffer?
Then process continues.
I assume that when Nagle is not used then BIG-IP will pass maximum allowed un ACKed bytes from Proxy Buffer to Send Buffer and then start to accumulate data in Proxy Buffer until Proxy Buffer High is reached.
Is above making any sense or I am completely wrong?
Piotr