On Mon, 15 May 2006 12:59:24 +0200 "Constantinos Makassikis" <cmakassikis@xxxxxxxxx> wrote: > On 5/12/06, Stephen Hemminger <shemminger@xxxxxxxx> wrote: > > > > Questions: > > > -------------- > > > > > > 1) Am I missing or misunderstanding something ? > > > > Linux does autotuning of send and receive buffer size. > > Since the buffer sizes are set manually via a setsockopt() call, isn't > autotuning supposed to be disabled ? Yes. then autotuning is disabled. > > > 2) Do you have any other ideas which could explain the low percentage reached ? > > > > Max is limited by tcp_rmem/tcp_wmem, read Documenation/networking/ip-sysctl.txt > > Indeed, but aren't tcp-rmem/tcp_wmem taken into account only when > autotuning is enabled ? The tcp_rmem[2] and tcp_wmem[2] are still an upper bound on the allowed socket memory. > Besides since I have set net.ipv4.tcp_moderate_rcvbuf = 0 , shouldn't > the receiver's autotuning be disabled ? yes > > > 4) Why is the advertized window steadily growing until it reaches 6 > > > MBytes instead of being given directly a size of 6 Mbytes at the > > > beginning of the connection ? > > > > Slow start and autotuning. > > Given the experiment's settings, I believe that autotuning is disabled > (cf. 1), 2)) > Isn't slow-start a tcp sender's side mechanism ? > > > > 5) Why does the advertized window remain stuck at 6 MBytes ? > > tcp_wmem > > Autotuning is normaly disabled (cf. 1), 2), 4)) > According to man tcp, it seems that by default linux tcp reserves 1/4 > of the receive buffer for buffering overhead. This is conditioned by > tcp_adv_win_scale variable. > Thus, the "real" receive buffer size is actually 12 Mbytes from which > only half is advertised ... > Still it doesn't explain why only half is advertised ... > > As for the sender's side, I still don't get how the tcp send buffer is managed. See john's explanation of the accounting. - : send the line "unsubscribe linux-net" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html