pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
DB sessions 100 times of DB connections
3+ messages / 2 participants
[nested] [flat]

* DB sessions 100 times of DB connections
@ 2014-07-04 01:44  Huang, Suya <Suya.Huang@au.experian.com>
  0 siblings, 1 reply; 3+ messages in thread

From: Huang, Suya @ 2014-07-04 01:44 UTC (permalink / raw)
  To: pgsql-performance

Hi,

We've experienced a DB issue yesterday and after checked the log found that the peak sessions is 3000 while the peak DB connections is only around 30. The application is having problem of pulling data but no warnings in DB log as it doesn't exceed max_connections.


How could this happen? How does sessions/connections work in Postgres?

Thanks,
Suya

^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: DB sessions 100 times of DB connections
@ 2014-07-04 01:59  Huang, Suya <Suya.Huang@au.experian.com>
  parent: Huang, Suya <Suya.Huang@au.experian.com>
  0 siblings, 1 reply; 3+ messages in thread

From: Huang, Suya @ 2014-07-04 01:59 UTC (permalink / raw)
  To: Huang, Suya <Suya.Huang@au.experian.com>; pgsql-performance

BTW, I'm using the pgbadger report to check for peak connections/sessions.

From: pgsql-performance-owner@postgresql.org [mailto:pgsql-performance-owner@postgresql.org] On Behalf Of Huang, Suya
Sent: Friday, July 04, 2014 11:44 AM
To: pgsql-performance@postgresql.org
Subject: [PERFORM] DB sessions 100 times of DB connections

Hi,

We've experienced a DB issue yesterday and after checked the log found that the peak sessions is 3000 while the peak DB connections is only around 30. The application is having problem of pulling data but no warnings in DB log as it doesn't exceed max_connections.


How could this happen? How does sessions/connections work in Postgres?

Thanks,
Suya

^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: DB sessions 100 times of DB connections
@ 2014-07-08 16:28  Steve Crawford <scrawford@pinpointresearch.com>
  parent: Huang, Suya <Suya.Huang@au.experian.com>
  0 siblings, 0 replies; 3+ messages in thread

From: Steve Crawford @ 2014-07-08 16:28 UTC (permalink / raw)
  To: Huang, Suya <Suya.Huang@au.experian.com>; pgsql-performance

On 07/03/2014 06:59 PM, Huang, Suya wrote:
>
> BTW, I'm using the pgbadger report to check for peak connections/sessions.
>
> *From:*pgsql-performance-owner@postgresql.org 
> [mailto:pgsql-performance-owner@postgresql.org] *On Behalf Of *Huang, Suya
> *Sent:* Friday, July 04, 2014 11:44 AM
> *To:* pgsql-performance@postgresql.org
> *Subject:* [PERFORM] DB sessions 100 times of DB connections
>
> Hi,
>
> We've experienced a DB issue yesterday and after checked the log found 
> that the peak sessions is 3000 while the peak DB connections is only 
> around 30. The application is having problem of pulling data but no 
> warnings in DB log as it doesn't exceed max_connections.
>
> How could this happen? How does sessions/connections work in Postgres?
>
>
As handy as pgbadger is, I have found that its max-connections values 
don't pass the "sniff test" as it generally shows peak values that 
exceed the configured number of connections. I haven't dug in to find 
out why but could conjecture that the fact that log entries are 
generally truncated to the nearest second could cause this sort of thing.

Unexpected connection buildup is often a side-effect of something else 
like a large resource-intensive query, a query holding locks that 
prevent the other connections' queries from completing or a variety of 
other things.

If you are looking to solve/prevent the undescribed "issue", please 
provide more detail.

-Steve

^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2014-07-08 16:28 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2014-07-04 01:44 DB sessions 100 times of DB connections Huang, Suya <Suya.Huang@au.experian.com>
2014-07-04 01:59 ` Huang, Suya <Suya.Huang@au.experian.com>
2014-07-08 16:28   ` Steve Crawford <scrawford@pinpointresearch.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox