Re: [PERFORM] Slow query after 9.3 to 9.6 migration - Mailing list pgsql-performance

From Kevin Grittner
Subject Re: [PERFORM] Slow query after 9.3 to 9.6 migration
Date
Msg-id CACjxUsPd0nsLh37tpP+9dU92EYUAujSuhrEvncej_=EsSKiQ9A@mail.gmail.com
Whole thread Raw
In response to Re: [PERFORM] Slow query after 9.3 to 9.6 migration  (Flávio Henrique <yoshimit@gmail.com>)
List pgsql-performance
On Thu, Jan 5, 2017 at 10:51 AM, Flávio Henrique <yoshimit@gmail.com> wrote:

> Replying your comment, I think they tunned the server:
> effective_cache_size = 196GB
> shared_buffers = 24GB (this shouldn't be higher?)

Probably not, although it may be a good idea to try settings either
side of that (say, 16GB and 32GB) and monitor performance compared
to the current setting.

> autovacuum_max_workers              |3

If you ever see all workers busy at the same time for 30 minutes or
more, you should probably consider raising that so that small,
frequently updated tables are not neglected for too long.

> autovacuum_vacuum_cost_limit        |-1

That is going to default to vacuum_cost_limit, which is usually
200.  If the server is actually big enough to merit
"effective_cache_size = 196GB" then you should probably bump this
setting to something like 2000.

> autovacuum_work_mem                 |-1

That is going to default to maintenance_work_mem.  On a big
machine, you probably want that set to somewhere between 1GB and
2GB.

Some other tuning to the cost parameters might be helpful, but
there's not enough data on the thread to know what else to suggest.
If you hit some other slow query, you might want to report it in
the manner suggested here:

https://wiki.postgresql.org/wiki/SlowQueryQuestions

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-performance by date:

Previous
From: Flávio Henrique
Date:
Subject: Re: [PERFORM] Slow query after 9.3 to 9.6 migration
Next
From: Daniel Blanch Bataller
Date:
Subject: Re: [PERFORM] Slow query after 9.3 to 9.6 migration