Re: How to troubleshoot a halted postgres 8.3 ?
| От | Scott Mead |
|---|---|
| Тема | Re: How to troubleshoot a halted postgres 8.3 ? |
| Дата | |
| Msg-id | d3ab2ec80910200648v167d6e26k7552b8d9d6b2bb77@mail.gmail.com обсуждение |
| Ответ на | How to troubleshoot a halted postgres 8.3 ? ("stefan" <stefan@intermediate.de>) |
| Список | pgsql-admin |
On Tue, Oct 20, 2009 at 8:46 AM, stefan <stefan@intermediate.de> wrote:
Look at the pg_stat_activity and pg_locks views.
Hi,
I have a postgres 8.3 db in which I execute a transaction with a lot of alter tabel etc, update etc statements in a single transaction.
I also execute several select statements in parallel.
This puts my database in a state which I would describe as halted, i.e. the sql interface does not respond any more, pg_admin works and shows me several transactions running.
Remember, alter table statements require a full table lock. So if that transaction (including your update statements) doesn't end somehow (commit, rollback) then all other connections looking at that table will wait.
How do I proceed to analyze what's happened? Of course, my first thought is some kind of transaction deadlock, but how do I check for this ?
Look at the pg_stat_activity and pg_locks views.
--Scott
В списке pgsql-admin по дате отправления: