Re: [PERFORM] Simple SQL too slow - Mailing list pgsql-performance

From Tomas Vondra
Subject Re: [PERFORM] Simple SQL too slow
Date
Msg-id 7152357d-5cac-20d6-9c08-ea56878c3d03@2ndquadrant.com
Whole thread Raw
In response to Re: [PERFORM] Simple SQL too slow  (Daviramos Roussenq Fortunato <daviramosrf@gmail.com>)
Responses Re: [PERFORM] Simple SQL too slow  (Julien Rouhaud <julien.rouhaud@dalibo.com>)
List pgsql-performance
Hello,

On 07/01/2017 10:39 PM, Daviramos Roussenq Fortunato wrote:
> What tests could I do. Rigid Linux disk is much faster than Windows, I
> should get a much better perfomace on this Linux. What test battery do
> you recommend I do?
>

I'm not sure what you mean by "rigid disk" or "test battery", but I
agree with Andreas that clearly there's something wrong at the system
level. It's hard to guess what exactly, but sequential scan on 250MB
table (computed the relpages values) should only take a few seconds on
any decent hardware, and not 3 or 7 minutes.

The first thing I would do is running basic system-level tests, for
example benchmarking storage using fio.

After that, you need to determine what is the bottleneck. Perhaps the
resources are saturated by something else running on the system - other
queries, maybe something else running next to PostgreSQL. Look at top
and iotop while running the queries, and other system tools.

regards

--
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


pgsql-performance by date:

Previous
From: Daviramos Roussenq Fortunato
Date:
Subject: Re: [PERFORM] Simple SQL too slow
Next
From: Julien Rouhaud
Date:
Subject: Re: [PERFORM] Simple SQL too slow