agora inbox for postgres@postgres.berkeley.edu  
help / color / mirror / Atom feed
From: Paul M. Aoki <aoki@postgres.Berkeley.EDU>
To: shlam@ie.cuhk.hk
Cc: postgres@postgres.Berkeley.EDU
Subject: Re: how to clean up pg_log, pg_time and pg_variable?
Date: Mon, 06 Jun 94 02:57:46 -0700
Message-ID: <199406060957.CAA13241@faerie.CS.Berkeley.EDU> (raw)
In-Reply-To: <9406060939.AA14430@eng.ie.cuhk.hk>

shlam@ie.cuhk.hk writes:
> I discover that the size of $postgres/data/pg_log, pg_time and
> pg_variable grow very large.

pg_variable should never grow beyond one disk page (8k).

with respect to the other two, pg_log grows at 2 bits (.25 bytes) per
transaction and pg_time grows at 4 bytes per transaction.

> Is there any command to clean up or reset these files ?

what pg_log and pg_time store are the commit status and commit time of
each transaction.  in theory, this could be compressed by something
like run-length encoding (since most transactions commit) or truncated
after vacuuming (if you could somehow arrange to vacuum the entire
installation..).  in fact, they just grow.

it would be a bad idea to remove them or truncate them.
--
  Paul M. Aoki  |  CS Div., Dept. of EECS, UCB  |  aoki@postgres.Berkeley.EDU
                |  Berkeley, CA 94720           |  ...!uunet!ucbvax!aoki

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU"

   If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================



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 using the --to and --cc options:
  reply via email

  To: postgres@postgres.berkeley.edu
  Cc: aoki@postgres.Berkeley.EDU, shlam@ie.cuhk.hk
  Subject: Re: how to clean up pg_log, pg_time and pg_variable?
  In-Reply-To: <199406060957.CAA13241@faerie.CS.Berkeley.EDU>

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

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