Re: tcp question

From: Nagendra Singh Tomar (nagendra_tomar@adaptec.com)
Date: Tue Jul 29 2003 - 23:59:36 EST


On Wed, 30 Jul 2003, Kallol Biswas wrote:

> Someone asked the following questions, I know there are many gurus on
> the net:
>
>
> on winsock:
>
> 1. How does an application determine send buffer when it issues send
> call ?

It need not determine, but if it wishes it can do so using
getsockopt(SO_SNDBUF)

>
> 2. Is there relation between send buffer and size of tcp receive window
> as sent by the receiving end ?

The other ends receive buffer has a direct relation to the receive window
advertised, Our send buffer size has no relation, but it does not make
much sense to have a very large send buffer if the other end always
advertises a small receive window.

>
> 3. If, in a packet trace, I see sender who puts a push bit after every
> 64K, does that mean that the sender uses a 64K send buffer
> when he issued send call ?

Not really, but it might be so. Normally TCP sets the PSH flag on whenever
it can send everything the application has asked it to.

>
> 4. Is the use of push bit in send call optional ?

BSD sockets API do not provide any way for the application to ask TCP to
set PSH flag on.

>
> 5. Why would you do that in a non-interactive application ? (i.e. bulk
> transfer: printing).

Same as above. TCP takes this decision not the app.

tomar
>
>
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-net" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>

-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html



This archive was generated by hypermail 2b29 : Thu Jul 31 2003 - 22:00:02 EST