Re: [GENERAL] Weird performance difference

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [GENERAL] Weird performance difference
Дата
Msg-id 13423.1508546313@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [GENERAL] Weird performance difference  (Israel Brewster <israel@ravnalaska.net>)
Ответы Re: [GENERAL] Weird performance difference  (israel <israel@ravnalaska.net>)
Re: [GENERAL] Weird performance difference  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-general
Israel Brewster <israel@ravnalaska.net> writes:
>> Can you send "explain" (not explain analyze) for the production server?

> Not for the full query - it only just completed, after 70 minutes or so, and I wasn't running under EXPLAIN ANALYZE.
Runningwith a shorter date range of only 7 days, as you suggest below: https://explain.depesz.com/s/r80j
<https://explain.depesz.com/s/r80j>

First thing that jumps out from that is

> Foreign Scan on oag_schedules (cost=100.00..128.60 rows=620 width=108) (actual time=3.576..477.524 rows=79,853
loops=1)

Being off by a factor of 100 at the scan level is never a good start for a
join plan.  Turn on use_remote_estimate (assuming these are postgres_fdw
tables).  Also try explicitly ANALYZE'ing the foreign tables.  I do not
believe auto-analyze will touch foreign tables ...
        regards, tom lane


--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

В списке pgsql-general по дате отправления:

Предыдущее
От: Israel Brewster
Дата:
Сообщение: Re: [GENERAL] Weird performance difference
Следующее
От: doganmeh
Дата:
Сообщение: [GENERAL] Restoring tables with circular references dumped to separate files