pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
VACUUMing a live site OK?
2+ messages / 2 participants
[nested] [flat]

* VACUUMing a live site OK?
@ 2001-10-18 16:20  Shuzo Kubo <gardenweasel@hotmail.com>
  0 siblings, 1 reply; 2+ messages in thread

From: Shuzo Kubo @ 2001-10-18 16:20 UTC (permalink / raw)
  To: pgsql-admin

Hi,

I have a web application using PostgreSQL 7.1.3 with a table that
experiences alot of UPDATEs. I shouldn't be updating the data so much to
start off with but can no longer avoid the situation.

I would like to vacuum a table (1 table only) to maintain an acceptable
performance. Is it safe to vacuum a table when users are attempting to
SELECT from or UPDATE to it? I would imagine that the table would get locked
and there should be no problems.

Any help is greatly appreciated. Thank you very much in advance.




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

* Re: VACUUMing a live site OK?
@ 2001-10-19 16:08  Stephan Szabo <sszabo@megazone23.bigpanda.com>
  parent: Shuzo Kubo <gardenweasel@hotmail.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Stephan Szabo @ 2001-10-19 16:08 UTC (permalink / raw)
  To: Shuzo Kubo <gardenweasel@hotmail.com>; +Cc: pgsql-admin

On Fri, 19 Oct 2001, Shuzo Kubo wrote:

> Hi,
> 
> I have a web application using PostgreSQL 7.1.3 with a table that
> experiences alot of UPDATEs. I shouldn't be updating the data so much to
> start off with but can no longer avoid the situation.
> 
> I would like to vacuum a table (1 table only) to maintain an acceptable
> performance. Is it safe to vacuum a table when users are attempting to
> SELECT from or UPDATE to it? I would imagine that the table would get locked
> and there should be no problems.

That should be fine.  The vacuum should wait until any transactions
currently locking the table finish and any other transactions that want to
access the table should wait for the vacuum. One warning is that if you
have any kind of persistant connections, you may see things were a
transaction has a lock and goes idle (no statements) which will cause
the vacuum to sit and wait and other transactions to line up behind it.





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


end of thread, other threads:[~2001-10-19 16:08 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-10-18 16:20 VACUUMing a live site OK? Shuzo Kubo <gardenweasel@hotmail.com>
2001-10-19 16:08 ` Stephan Szabo <sszabo@megazone23.bigpanda.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