Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 10A95634181 for ; Fri, 10 Apr 2009 14:11:52 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 84496-01 for ; Fri, 10 Apr 2009 14:11:49 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from EXHUB018-3.exch018.msoutlookonline.net (exhub018-3.exch018.msoutlookonline.net [64.78.17.18]) by mail.postgresql.org (Postfix) with ESMTP id A19BA633DEE for ; Fri, 10 Apr 2009 14:11:49 -0300 (ADT) Received: from EXVMBX018-1.exch018.msoutlookonline.net ([64.78.17.47]) by EXHUB018-3.exch018.msoutlookonline.net ([64.78.17.18]) with mapi; Fri, 10 Apr 2009 10:11:47 -0700 From: Scott Carey To: Josh Berkus , henk de wit CC: "jesper@krogh.cc" , "pgsql-performance@postgresql.org" Date: Fri, 10 Apr 2009 10:11:46 -0700 Subject: Re: Using IOZone to simulate DB access patterns Thread-Topic: [PERFORM] Using IOZone to simulate DB access patterns Thread-Index: Acm5nxwt5pLCefJhSHWsqVl7s7jJZgAYFE5Z Message-ID: In-Reply-To: <49DEDC1B.7080303@agliodbs.com> Accept-Language: en-US Content-Language: en X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200904/197 X-Sequence-Number: 33564 I've switched to using FIO. Bonnie in my experience produces poor results and is better suited to testing desktop/workstation type load. Most of its tests don't apply to ho= w postgres writes/reads anyway. IOZone is a bit more troublesome to get it to work on the file(s) you want under concurrency and is also hard to get it to avoid the OS file cache. O= n systems with lots of RAM, it takes too long as a result. I personally lik= e it better than bonnnie by far, but its not flexible enough for me and is often used by hardware providers to 'show' theier RAID cards are doing fine (PERC 6 doing 4GB /sec file access -- see! Its fine!) but the thing is jus= t testing in memory cached reads for most of the test or all if not configure= d right... FIO with profiles such as the below samples are easy to set up, and they ca= n be mix/matched to test what happens with mixed read/write seq/rand -- with surprising and useful tuning results. Forcing a cache flush or sync before or after a run is trivial. Changing to asynchronous I/O, direct I/O, or other forms is trivial. The output result formatting is very useful as well. I got into using FIO when I needed to test a matrix of about 400 different tuning combinations. This would have taken a month with Iozone, but I coul= d create my profiles with FIO, force the OS cache to flush, and constrain the time appropriately for each test, and run the batch overnight. #---------------- [read-rand] rw=3Drandread ; this will be total of all individual files per process size=3D1g directory=3D/data/test fadvise_hint=3D0 blocksize=3D8k direct=3D0 ioengine=3Dsync iodepth=3D1 numjobs=3D32 ; this is number of files total per process nrfiles=3D1 group_reporting=3D1 runtime=3D1m exec_prerun=3Decho 3 > /proc/sys/vm/drop_caches #-------------------- [read] rw=3Dread ; this will be total of all individual files per process size=3D512m directory=3D/data/test fadvise_hint=3D0 blocksize=3D8k direct=3D0 ioengine=3Dsync iodepth=3D1 numjobs=3D8 ; this is number of files total per process nrfiles=3D1 runtime=3D30s group_reporting=3D1 exec_prerun=3Decho 3 > /proc/sys/vm/drop_caches #---------------------- [write] rw=3Dwrite ; this will be total of all individual files per process size=3D4g directory=3D/data/test fadvise_hint=3D0 blocksize=3D8k direct=3D0 ioengine=3Dsync iodepth=3D1 numjobs=3D1 ;rate=3D10000 ; this is number of files total per process nrfiles=3D1 runtime=3D48s group_reporting=3D1 end_fsync=3D1 exec_prerun=3Decho 3 >sync; /proc/sys/vm/drop_caches On 4/9/09 10:41 PM, "Josh Berkus" wrote: > All, >=20 > Wow, am I really the only person here who's used IOZone? >=20 > -- > Josh Berkus > PostgreSQL Experts Inc. > www.pgexperts.com >=20 > -- > Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org= ) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-performance >=20