home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.protocols.tcp-ip
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!news.sei.cmu.edu!fs7.ece.cmu.edu!crabapple.srv.cs.cmu.edu!cmaeda
- From: cmaeda+@cs.cmu.edu (Christopher Maeda)
- Subject: bug in ttcp: SO_RCVBUF, accept
- Message-ID: <C172rz.At9.1@cs.cmu.edu>
- Sender: news@cs.cmu.edu (Usenet News System)
- Nntp-Posting-Host: kona.mach.cs.cmu.edu
- Organization: School of Computer Science, Carnegie Mellon
- Date: Thu, 21 Jan 1993 08:11:53 GMT
- Lines: 39
-
-
- I noticed the following weird behavior using ttcp and the 4.3BSD TCP.
- (Actually a Mach 3.0 system but the binaries and the TCP code are
- 4.3BSD Unix).
-
- I wanted ttcp to advertise receive windows larger than 4k so I invoked
- it as follows:
-
- ttcp -r -s -b 32768 -l 16384
-
- However, packet traces were showing that the receive windows were
- always 4k. For the arguments above, ttcp does the following syscalls:
-
- fd = socket(AF_INET,SOCK_STREAM,0);
- setsockopt(fd,SOL_SOCKET,SO_RCVBUF,...); /* 32k rcv window */
- listen(fd,...);
- fd = accept(fd,...)
-
- In the TCP I'm using, the accept'ed connection doesn't pick up the
- modified sockbuf parameters from the parent socket and therefore the
- accept'ed connection has the 4k default receive window size. If I
- change the order of calls to the following, the accept'ed connection
- advertises 32k receive windows.
-
- fd = socket(AF_INET,SOCK_STREAM,0);
- listen(fd,...);
- fd = accept(fd,...)
- setsockopt(fd,SOL_SOCKET,SO_RCVBUF,...); /* 32k rcv window */
-
- So my question is this. Is the second syscall sequence what ttcp
- *should* have been doing or should the accept'ed socket have inherited
- the sockbuf parameters from the parent socket (and therefore my TCP is
- buggy).
-
- --
- Chris Maeda, Grad Student and RetroGrouch <cmaeda@cs.cmu.edu>
- "A unix signature isn't a return address, it's the ASCII equivalent of
- a black velvet clown painting. It's a rectangle of carets surrounding
- a quote from a literary giant of weeniedom like Heinlein or Dr. Who."
-