From: Jim C. Nasby <jim@nasby.net>
To: Merlin Moncure <mmoncure@gmail.com>
Cc: Pg Performance list <pgsql-performance@postgresql.org>
Subject: Re: odd variances in count(*) times
Date: Mon, 9 Oct 2006 16:23:56 -0500
Message-ID: <20061009212355.GM72517@nasby.net> (raw)
In-Reply-To: <b42b73150610091141n487ba223pfa56a639105f0e9f@mail.gmail.com>
References: <b42b73150610091117n29e8d9d5yed07abe8a228593e@mail.gmail.com>
<20061009183026.GT24675@kenobi.snowman.net>
<b42b73150610091141n487ba223pfa56a639105f0e9f@mail.gmail.com>
On Mon, Oct 09, 2006 at 02:41:07PM -0400, Merlin Moncure wrote:
> On 10/9/06, Stephen Frost <sfrost@snowman.net> wrote:
> >* Merlin Moncure (mmoncure@gmail.com) wrote:
> >> explain analyze select 5000!;
> >> A: 2.4 seconds
> >> B: 1.8 seconds
> >>
> >> explain analyze select count(*) from generate_series(1,500000);
> >> A: 0.85 seconds
> >> B: 4.94 seconds
> >
> >Try w/o the explain analyze. It adds quite a bit of overhead and that
> >might be inconsistant between the systems (mainly it may have to do with
> >the gettimeofday() calls being implemented differently between Windows
> >and Linux..).
>
> that was it. amd system now drop to .3 seconds, windows .6. (doing
> time foo > psql -c bar > file). thanks...
You can also turn timing on in psql.
And FWIW, RAID5 generally isn't a good idea for databases.
--
Jim Nasby jim@nasby.net
EnterpriseDB http://enterprisedb.com 512.569.9461 (cell)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: jim@nasby.net, mmoncure@gmail.com
Subject: Re: odd variances in count(*) times
In-Reply-To: <20061009212355.GM72517@nasby.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox