Re: pg_ctl patch to integrate apache's rotatelogs

From: Andrew Hammond <ahammond(at)ca(dot)afilias(dot)info>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: pg_ctl patch to integrate apache's rotatelogs
Date: 2004-05-14 17:14:32
Message-ID: 40A4FE78.3030709@ca.afilias.info
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Peter Eisentraut wrote:
| Am Freitag, 14. Mai 2004 17:35 schrieb Andrew Hammond:
|
|>Please find attached a patch to integrate rotatelogs into pg_ctl. I've
|>noticed a couple of questions about how to do this and it seems easier
|>(and more elegant) to solve it in code rather than in documentation. The
|>patch is pretty simple and I've made it reasonably self documenting. It
|>test for apache rotatelogs only when unless it is specifically used.
|>This code only adds functionality and causes no changes to current usage.
|
|
| How is this better than just piping the output of pg_ctl into rotatelogs?

That's essentially what the patch does. It's better because it does it
correctly instead of requiring an admin to learn how to do it correctly.
pg_ctl already has a -l option. I think it also makes a certain amount
of sense to keep as much of the logging stuff in one place as possible:

pg_ctl -l foo.log start

Oh... I need log rotation...

pg_ctl -l foo.log -r 10M start

Drew
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFApP5ygfzn5SevSpoRAqpwAKC23sHnxEBcg5y9umOxlIyhph6NhACeLmbF
c3Sne4Z7BFk0c7tkj7jaZEo=
=cSWp
-----END PGP SIGNATURE-----

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Neil Conway 2004-05-14 17:31:21 Re: SQLState
Previous Message David Fetter 2004-05-14 17:14:08 YA dollar quoting patch