troubleshooting a database that keeps locking up

From: Jonathan Vanasco <postgres(at)2xlp(dot)com>
To: PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: troubleshooting a database that keeps locking up
Date: 2014-11-13 16:36:18
Message-ID: 338A69C1-E7C5-4290-A534-696D91026B12@2xlp.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


I have a database that has started to constantly hang after a brief period of activity

looking at `select * from pg_stat_activity;` I roughly see the following each time:

process 1 | <IDLE>
process 2 | <IDLE> in transaction
process 3 | <IDLE> in transaction
process 4 | <IDLE>
process 5 | <IDLE>
process 6 | <IDLE>
process 7 | INSERT INTO table_a ........ RETURNING id

occasionally I'll see

process 8 | UPDATE table_b

Does anyone have tips on how I can troubleshoot this.

I was hoping there would be some way to show the history of the "<IDLE> in transaction" processes, but I couldn't find them.

I was also wondering if the "RETURNING id" might have something to do with this.

I'd appreciate any pointers in trying to figure out what is causing this.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2014-11-13 17:24:55 Re: troubleshooting a database that keeps locking up
Previous Message Jonathan Vanasco 2014-11-13 16:10:42 Re: Modeling Friendship Relationships