Re: [ADMIN] blocking issue when create index concurrently

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [ADMIN] blocking issue when create index concurrently
Дата
Msg-id 1878.1481823217@sss.pgh.pa.us
обсуждение исходный текст
Ответ на [ADMIN] blocking issue when create index concurrently  (xu jian <jamesxu@outlook.com>)
Ответы [ADMIN] 答复: [ADMIN] blocking issue when create index concurrently  (xu jian <jamesxu@outlook.com>)
Список pgsql-admin
xu jian <jamesxu@outlook.com> writes:
>           I was trying to create 2 indexes concurrently(on different table) in same database. I didn't expect the
firstcreate index operation would block the other one since they were running on different table. 

> However, it is not true. I found one creating index command was blocking the other one.

There are (IIRC) two separate points in CREATE INDEX CONCURRENTLY where it
has to wait for all other transactions to exit.  That would include a
transaction running another CREATE INDEX (CONCURRENTLY), even if it's for
a different table.  I think running two at once would end in a deadlock
failure, since they would likely end up waiting for each other.

Usually, if you're using C.I.C., you're trying to minimize the impact
on the rest of the system, so running two at once seems a bit
counterproductive anyway.

            regards, tom lane


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

Предыдущее
От: Payal Singh
Дата:
Сообщение: Re: [ADMIN] Database corrupted - PSQL 9.3 Ubuntu Server 14.04
Следующее
От: xu jian
Дата:
Сообщение: [ADMIN] 答复: [ADMIN] blocking issue when create index concurrently