Re: Index recreation details with REINDEX TABLE CONCURRENTLY

Поиск
Список
Период
Сортировка
От Ron
Тема Re: Index recreation details with REINDEX TABLE CONCURRENTLY
Дата
Msg-id 5ec087d5-e07c-e704-96cd-a3f8fb9f91d7@gmail.com
обсуждение исходный текст
Ответ на Index recreation details with REINDEX TABLE CONCURRENTLY  (Matthew Planchard <matthew@specprotected.com>)
Список pgsql-admin
On 5/10/23 10:04, Matthew Planchard wrote:
> Hello,
>
> We're working on setting up some regular jobs to reindex tables where we
> wind up generating a lot of index bloat. We're planning on using REINDEX
> ... CONCURRENTLY. We'd like to reindex all of the indexes on the tables.
>
> In some of our environments, these tables are very large and under high
> load, and we want to minimize the resource consumption of index
> recreation if possible.
>
> With that in mind, my question is: does REINDEX TABLE CONCURRENTLY
> operate on the indexes of the table in parallel, or sequentially? If
> in parallel, I imagine we would see less DB resource utilization by
> updating one index at a time.

https://www.postgresql.org/docs/11/sql-createindex.html

The CREATE INDEX page certainly mentions parallel index builds.  It would 
definitely be very good to know whether REINDEX TABLE CONCURRENTLY can have 
multiple "threads" leveraging table data already in cache so as not to have 
to reread the whole table each time.

That (concurrent CREATE INDEX statements) really sped things up Back In The 
Day).

-- 
Born in Arizona, moved to Babylonia.



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

Предыдущее
От: Dhirendra Singh
Дата:
Сообщение: Re: Question about pg_wal.tar.gz generated by pg_basebackup
Следующее
От: James Fraley
Дата:
Сообщение: Re: Index recreation details with REINDEX TABLE CONCURRENTLY