Search Postgresql Archives

Re: Meaning of query age in pg_stat_activity

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



So the query is just the latest query and the time is the transaction time since this query, i suppose ?
Thanks for your answer, i will try to make the transaction shorter as you suggest.

On Tue, Jan 30, 2018 at 12:29 AM, Nikolay Samokhvalov <samokhvalov@xxxxxxxxx> wrote:
On Mon, Jan 29, 2018 at 3:19 PM, Jan De Moerloose <jan@xxxxxxxxxxxx> wrote:
The state is 'idle in transaction'.

So you have long-running *transactions*, not queries. This is not good for an OLTP system, because some transaction can wait of others, which are "idle in transaction" but do nothing at the moment. Think how you can make them shorter, commit faster.

Also, if your server version is 9.6+ consider setting idle_in_transaction_session_timeout to some low value:



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux