Re: create index concurrently blocked by other query

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: James Pang <jamespang886(at)gmail(dot)com>
Cc: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: Re: create index concurrently blocked by other query
Date: 2024-03-23 16:37:22
Message-ID: 1409589.1711211842@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

James Pang <jamespang886(at)gmail(dot)com> writes:
> PGv14, it's a time range partition table, we first create index ... on
> ONLY parent table and it's done very fast, then we are doing "create index
> concurrently ... on each partition table", then we saw it blocked by some
> other sessopm "select on other tables" , is it expected ?

Yes, read the documentation. CONCURRENTLY avoids blocking other
transactions, at the cost of being easily blocked itself.

regards, tom lane

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Keith 2024-03-24 02:46:08 Re: PG_PARTMAN - Create Child With FillFactor
Previous Message Laurenz Albe 2024-03-23 13:33:39 Re: Cursor with hold for select