From: Andrew Sullivan <andrew@libertyrms.info>
To: pgsql-admin@postgresql.org
Subject: Re: database running slow
Date: Tue, 13 May 2003 08:14:19 -0400
Message-ID: <20030513121419.GC17278@libertyrms.info> (raw)
In-Reply-To: <20030512185511.95439.qmail@web21102.mail.yahoo.com>
References: <20030512185511.95439.qmail@web21102.mail.yahoo.com>
On Mon, May 12, 2003 at 11:55:11AM -0700, Shankar K wrote:
> Since our application involves high inserts/deletes,
> we vacuum/analyze major tables thrice a day. Apart
> from this
Be sure you really need the vacuum before you do it. Remember,
vacuum destroys your buffers, so it's not free. On certain kinds of
tables, it can be worth it to do a vacuum very often (we have some we
do once an hour).
> 1. how to identify run-away sql backends
Define "run-away". You can look for long-running transactions; that
might be helpful.
> 2. find out the bad sqls thats causing trouble
Look for queries that take a long time. EXPLAIN ANALYSE is your
friend.
A
--
----
Andrew Sullivan 204-4141 Yonge Street
Liberty RMS Toronto, Ontario Canada
<andrew@libertyrms.info> M2P 2A8
+1 416 646 3304 x110
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: andrew@libertyrms.info
Subject: Re: database running slow
In-Reply-To: <20030513121419.GC17278@libertyrms.info>
References: <20030512185511.95439.qmail@web21102.mail.yahoo.com> <20030513121419.GC17278@libertyrms.info>
* 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