Re: socket programming - tcp MSS

From: Sandeep Agarwal (sandeep@engr.orst.edu)
Date: Wed Feb 09 2000 - 21:47:11 EST


Through tcp sockets you can send as much data as you want but tcp will
only send 1448 data bytes per packet to the receiver...
In linux getsockopt allows you to get TCP_MAXSEG but you cannot set it. We
can set the RCV_BUF and SND_BUF which are used for the window
advertisements...
for NSPROTO_SPP we can get and set the SO_MTU size(type u_short)...
hth

On Wed, 9 Feb 2000, Akshay Adhikari wrote:

> Hi linux net
>
> The question I have is -
>
> 1. What is the max data buffer I can send through TCP sockets? Is it limited by the device MTU (if the device is , say ethernet, its MTU is 1500 bytes). Or can I send buffers of the size of 16KB, 64 KB etc?
>
> 2. Also the problem specifically in Linux TCP. Setsockopt () allows you to set the MSS (Max data buffer size of TCP). The field is 16 bit, so the MSS can be at most 16 KB. But in the TCP setsockopt code, theres a comment that says - (MSS) values greater than device MTU wont take effect.
>
> So theres the question again. How much can I send in one packet??. Is it that to avoid fragmentation of a segment , Linux TCP doesnt send more data than device MTU in one packet?
>
> Thanks
> Akshay
>

Sandeep Agarwal
Electrical & Computer Engineering DearBorn Hall 208
Corvallis, OR, Phone: 541 737 2349
Fax: 541 737 1300 Mail:sandeep@engr.orst.edu
                http://www.ece.orst.edu/~sandeep

-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.rutgers.edu



This archive was generated by hypermail 2b29 : Tue Feb 15 2000 - 21:00:35 EST