From owner-freebsd-current@FreeBSD.ORG Sun Nov 12 04:01:11 2006 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A981616A407; Sun, 12 Nov 2006 04:01:10 +0000 (UTC) (envelope-from amistry@am-productions.biz) Received: from mail.united-ware.com (am-productions.biz [69.61.164.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1460F43D53; Sun, 12 Nov 2006 04:01:09 +0000 (GMT) (envelope-from amistry@am-productions.biz) Received: from [192.168.1.100] (cpe-24-210-75-119.columbus.res.rr.com [24.210.75.119]) (authenticated bits=0) by mail.united-ware.com (8.13.6/8.13.6) with ESMTP id kAC4KmWT087862 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 11 Nov 2006 23:20:55 -0500 (EST) (envelope-from amistry@am-productions.biz) From: Anish Mistry Organization: AM Productions To: freebsd-current@freebsd.org Date: Sat, 11 Nov 2006 23:02:13 -0500 User-Agent: KMail/1.9.4 References: <200611021653.kA2GrRWx008044@repoman.freebsd.org> <4555BA65.4020603@gmail.com> <45560FB8.1040607@freebsd.org> In-Reply-To: <45560FB8.1040607@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1241153.xUBksLBTLO"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200611112302.23508.amistry@am-productions.biz> X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_50,MYFREEBSD2, MYFREEBSD3,RCVD_IN_NJABL_DUL,SPF_SOFTFAIL autolearn=failed version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on mail.united-ware.com X-Virus-Scanned: ClamAV 0.88.5/2187/Sat Nov 11 11:49:23 2006 on mail.united-ware.com X-Virus-Status: Clean X-Mailman-Approved-At: Sun, 12 Nov 2006 05:06:48 +0000 Cc: Andre Oppermann , current@freebsd.org Subject: Re: sendfile data corruption X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Nov 2006 04:01:11 -0000 --nextPart1241153.xUBksLBTLO Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Saturday 11 November 2006 13:00, Andre Oppermann wrote: > Pawel Worach wrote: > > Andre Oppermann wrote: > >> I'm looking into the problem. Please try a binary FTP transfer > >> as well and check if the checksums match. ftpd uses sendfile(2) > >> as well but w/o headers or trailers and does the send in one > >> swoop. > > > > Oh, didn't think of that, ftpd is ok, transferring a 64MB file > > does not trash it. Meanwhile a couple of other things where > > tested, SMP disabled (removed from kernel config), added some > > printf's which when printing to a serial console moves the offset > > where the breakage begins to 0x01000000, sometimes. > > I tried to reproduce the problem with lighttpd w/o success. > > My guess is that something gets wrong when using non-blocking > sockets and the http headers. Could you obtain the truss of the > sendfile(2) calls so I get the input parameters to it? A visual > inspection of a corruptly transferred text file would be helpful > too. This should give more hints what happens, like duplicated or > missing pages, etc. =46or me I'm seeing 3 different behaviors. 1) The file is just truncated after a few KB. 2) A section of the file is just missing. eg. A small section of the=20 file in the middle is just gone. 3) The data is sent before the headers. eg. a portion of the html is=20 sent, and then you see The following shows 1) and 2). http://am-productions.biz/docs/no-menu-default.css.bad http://am-productions.biz/docs/no-menu-default.css =2D-=20 Anish Mistry amistry@am-productions.biz AM Productions http://am-productions.biz/ --nextPart1241153.xUBksLBTLO Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (FreeBSD) iD8DBQBFVpzPxqA5ziudZT0RAqHpAJ4xT04UksCE6sRsnFy+1hinBnuZPwCglxsj 9YKUDhJQFSACHz24dK+lInE= =Ao4E -----END PGP SIGNATURE----- --nextPart1241153.xUBksLBTLO--