pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Anj Adu <fotographs@gmail.com>
To: Benjamin Krajmalnik <kraj@servoyant.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Strange performance issue apparently causd by pg_stat timeout
Date: Sat, 5 Jun 2010 07:19:51 -0700
Message-ID: <AANLkTilOnXzVqVgAw2GGO0ZoPRglbHogecqApRVlWM0x@mail.gmail.com> (raw)
In-Reply-To: <F4E6A2751A2823418A21D4A160B6898861451E@fletch.stackdump.local>
References: <AcsCz6Tfk1cC+YPQQMSQraMQsZ+tyw==>
	<F4E6A2751A2823418A21D4A160B6898861451E@fletch.stackdump.local>

We run a similar system with very large volumes

I had similar queue build ups (not related to pg_stat_timeouts though)

I was using Rules for my partition management instead of triggers.

Changing from rules to triggers fixed the problem. (rules were extremely slow)

Hope this helps you.

On Wed, Jun 2, 2010 at 8:48 PM, Benjamin Krajmalnik <kraj@servoyant.com> wrote:
> System is running PG 8.4.0 (I have been unable to upgrade because the system
> needs to be up 24x7), FreeBSD 7.2 amd64, 8 cores, 16GB RAM.
>
> Our application is a network monitoring system, so we are constantly
> inserting vast amounts of data (server presently processes about 50 million
> transactions per day).
>
> As digests of test points come in, they are stored in message queues on a
> second server (running PG 8.4.4).  A set of daemons process the digests and
> insert the data into the main database residing on a second server.
> Presently, the database has about 60GB of data.
>
>
>
> A few days ago, I noticed that the data in the message queues on the other
> server was getting backed up, and then after a few minutes it would process
> and clear.  This was a totally new behavior.   Initially I suspected
> deadlocks caused by background processes which create materialized views, so
> I stopped those, yet the behavior continued.  Then I suspected server load,
> yet CPU utilization and load was fine (l minute and 5 minute load was at <
> 4), and iostat did not show an overly busy disk subsystem (I had seen it at
> much higher utilization levels on both the data and log partitions without
> any performance hits).
>
>
>
> I then suspected network issues, so I checked the infrastructure (runnig on
> Juniper Gig switches, of course non-blocking, and all of the port
> information was clean).
>
> Finally, I noticed that the logs had “pg_stat wait timeout” warnings.
> Initially I though these were caused by our checking the running process via
> pgadmin from our office to the data center, yet even when I exited pgadmin,
> the warnings were still there.
>
> After further testing, I saw a correlation between the data getting queued
> up and the “pg_stat wait timeout” warnings.  As data would begin to queue
> up, I would see the warnings, and about a minute later it would start to
> dequeue and get stored on the server.
>
>
>
> I searched the archives and found some messages stating that this has been
> observed.  The interesting thing is that nothing has changed on the server
> and it started to manifest itself.  I ran an analyze of the entire database,
> hoping this may rectify any issue, but unfortunately to no avail.
>
>
>
> Any suggestions would be deeply appreciated – this behavior is definitely
> not good.
>
>
>
> Below is a snapshot from the log files:
>
>
>
> 2010-06-02 20:59:19 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:10:42 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:16:21 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:21:23 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:25:50 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:35:20 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:39:13 MDT WARNING:  pgstat wait timeout
>
> 2010-06-02 21:45:32 MDT WARNING:  pgstat wait timeout
>
>
>
> Thanks in advance.



view thread (3+ messages)  latest in thread

Message-ID: <AANLkTilOnXzVqVgAw2GGO0ZoPRglbHogecqApRVlWM0x@mail.gmail.com>
Permalink:  ../AANLkTilOnXzVqVgAw2GGO0ZoPRglbHogecqApRVlWM0x@mail.gmail.com/
Also on:    postgresql.org/message-id/AANLkTilOnXzVqVgAw2GGO0ZoPRglbHogecqApRVlWM0x@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: fotographs@gmail.com, kraj@servoyant.com
  Subject: Re: Strange performance issue apparently causd by pg_stat timeout
  In-Reply-To: <AANLkTilOnXzVqVgAw2GGO0ZoPRglbHogecqApRVlWM0x@mail.gmail.com>
  References: <AcsCz6Tfk1cC+YPQQMSQraMQsZ+tyw==> <F4E6A2751A2823418A21D4A160B6898861451E@fletch.stackdump.local> <AANLkTilOnXzVqVgAw2GGO0ZoPRglbHogecqApRVlWM0x@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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