Re: psql is hanging

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: psql is hanging
Дата
Msg-id 28459.1543595917@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: psql is hanging  (Ron <ronljohnsonjr@gmail.com>)
Ответы Re: psql is hanging
Список pgsql-general
Ron <ronljohnsonjr@gmail.com> writes:
> We have a seemingly identical problem in v9.6 on our big prod databases.  It
> worked perfectly in 8.4 *and works perfectly in 9.6 our small staging servers*.
> A giant sql script that drops the oldest child tables from a large set of
> partitioned tables (by dropping all relevant triggers, indexes, functions
> etc, dropping the oldest children, adding the new children then recreating
> all the relevant triggers, indexes, functions etc).

A script like that is going to be taking exclusive locks on a whole lot
of tables.  My guess is that you are running up against lock conflicts
against other activity in the DB, and that the "hang" is just waiting
for other transactions to release their table locks.  Looking into
the pg_locks view could be informative.

            regards, tom lane


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

Предыдущее
От: Steve Crawford
Дата:
Сообщение: Re: psql is hanging
Следующее
От: Geoff Winkless
Дата:
Сообщение: Re: psql is hanging