This message generated a parse failure. Raw output follows here. Please use 'back' to navigate. From devnull@lkml.org Sat May 21 23:22:27 2022 Received: from spaans.ds9a.nl (adsl-xs4all.ds9a.nl [213.84.159.51]) by kylie.puddingonline.com (8.11.6/8.11.6) with SMTP id g8IFjWX17727 for ; Wed, 18 Sep 2002 17:45:32 +0200 Received: (qmail 22726 invoked from network); 18 Sep 2002 07:05:10 -0000 Received: from unknown (HELO spaans.ds9a.nl) (3ffe:8280:10:360:202:44ff:fe2a:a1dd) by mayo.ipv6.ds9a.nl with SMTP; 18 Sep 2002 07:05:10 -0000 Received: (qmail 779 invoked by uid 1000); 17 Sep 2002 20:44:01 -0000 Received: (maildatabase); juh Received: (qmail 23507 invoked by alias); 8 Nov 2001 16:48:37 -0000 Received: (qmail 23504 invoked from network); 8 Nov 2001 16:48:36 -0000 Received: from vvtp.tn.tudelft.nl (HELO vvtp.nl) (qmailr@::ffff:130.161.252.29) by spaans.ds9a.nl with SMTP; 8 Nov 2001 16:48:36 -0000 Received: (qmail 31588 invoked by uid 2547); 8 Nov 2001 16:46:11 -0000 Received: (qmail 31505 invoked from network); 8 Nov 2001 16:46:08 -0000 Received: from vger.kernel.org (199.183.24.194) by vvtp.tn.tudelft.nl with SMTP; 8 Nov 2001 16:46:08 -0000 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Thu, 8 Nov 2001 11:46:23 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Thu, 8 Nov 2001 11:46:13 -0500 Received: from adsl-206-170-148-147.dsl.snfc21.pacbell.net ([206.170.148.147]:4 "HELO gw.goop.org") by vger.kernel.org with SMTP id ; Thu, 8 Nov 2001 11:46:02 -0500 Received: from ixodes.goop.org (ixodes.goop.org [192.168.0.5]) by gw.goop.org (Postfix) with ESMTP id 874F17847B; Thu, 8 Nov 2001 08:46:01 -0800 (PST) Subject: Re: [Ext2-devel] disk throughput From: Jeremy Fitzhardinge To: Constantin Loizides Cc: Linux Kernel List In-Reply-To: <3BEAA3B7.A7F9328E@isg.de> References: <3BE647F4.AD576FF2@zip.com.au> <3BE71131.59BA0CFC@zip.com.au> <20011106105138Z16653-12382+40@humbolt.nl.linux.org> <1005063444.25686.18.camel@ixodes.goop.org> <3BEAA3B7.A7F9328E@isg.de> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Evolution/0.99.0 (Preview Release) Date: 08 Nov 2001 08:46:01 -0800 Message-Id: <1005237961.4537.0.camel@ixodes.goop.org> Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org X-AntiVirus: scanned for viruses by AMaViS 0.2.1 (http://amavis.org/) X-AntiVirus: scanned for viruses by AMaViS 0.2.1 (http://amavis.org/) X-Spam-Tag: 1 Lines: 51 On Thu, 2001-11-08 at 07:24, Constantin Loizides wrote: > > > This is one I made a while ago while doing some measurements; its also > <[snip] > > That's an interesting plot. I would like to do one for my disk! > > How did you do it? > How do you find out about the seek distance??? > Do you create one big file and then start > seeking around accessing different blocks of it? Its pretty simple. I open /dev/hda (the whole device), and read random blocks, timing how long it takes for the data to come back since the last one. I set up a few hundred/thousand buckets, and accumulate the measured time into the bucket for that seek distance. So: fd=open("/dev/hda") llseek(fd, last = rand()); read(fd) while(!finished) { blk = rand(); llseek(fd, blk); read(fd); bucket[abs(last-blk)] = time; last = blk; } I found the random seeking was the only way I could get reasonable numbers out of the drive; any of the ordered patterns of the form "OK, lets measure N block seeks" seemed to be predicted by the drive and gave unreasonably fast results. This technique measures seek+rotational latency for reads. Seek-for-reading is generally faster than seek-for-writing, because they start reading as soon as the head is appoximately in the right place, and start using the data as soon as the ECCs start checking out OK. You certainly can't start writing until you've done the full head-settle time (another 1-2ms). I'll see what state my measurement code is in (technically and legally) and see if I can release it. Anyway I'm happy to answer questions. J - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/