From owner-freebsd-questions@FreeBSD.ORG Sat Feb 21 22:56:28 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0CCF3106564A for ; Sat, 21 Feb 2009 22:56:28 +0000 (UTC) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from wojtek.tensor.gdynia.pl (wojtek.tensor.gdynia.pl [IPv6:2001:4070:101:2::1]) by mx1.freebsd.org (Postfix) with ESMTP id 38BD88FC0A for ; Sat, 21 Feb 2009 22:56:26 +0000 (UTC) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from wojtek.tensor.gdynia.pl (localhost [IPv6:::1]) by wojtek.tensor.gdynia.pl (8.14.3/8.14.3) with ESMTP id n1LMuItw060484; Sat, 21 Feb 2009 23:56:18 +0100 (CET) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from localhost (wojtek@localhost) by wojtek.tensor.gdynia.pl (8.14.3/8.14.3/Submit) with ESMTP id n1LMuFfe060481; Sat, 21 Feb 2009 23:56:17 +0100 (CET) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Date: Sat, 21 Feb 2009 23:56:15 +0100 (CET) From: Wojciech Puchar To: Junsuk Shin In-Reply-To: <7873ac110902211146k6a8ee7d0pd67edc559ed14b15@mail.gmail.com> Message-ID: <20090221235530.C60480@wojtek.tensor.gdynia.pl> References: <7873ac110902211146k6a8ee7d0pd67edc559ed14b15@mail.gmail.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-questions@freebsd.org Subject: Re: read two files simultaneously X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Feb 2009 22:56:28 -0000 > I'm just guessing inode structure, the physical file location on HDD > might be related to this. But, if I read only one file, the size > doesn't matter. Reading file (10M, 100M, 700M) gives constantly about > 70MB/s, and the weird thing happens when I read 2 files of big size. if you use O_DIRECT it's read from disk exactly as you specified, without readahead, so you do a lot of seeks. simply use bigger buffer like 1MB