From: Peter Koczan <pjkoczan@gmail.com>
To: David Lowry <dlowry@bju.edu>
Cc: pgsql-admin@postgresql.org
Subject: Re: way to turn off epochs in log_filename
Date: Fri, 26 Oct 2007 15:25:26 -0500
Message-ID: <4544e0330710261325k708348fbm5c04eea44fd7ccc7@mail.gmail.com> (raw)
In-Reply-To: <E11307EB-94DF-4CDD-A89D-0C88A84F2B99@bju.edu>
References: <E11307EB-94DF-4CDD-A89D-0C88A84F2B99@bju.edu>
> The docs state that if there are no %-escapes in log_filename, then it will
> add the epoch onto the end of the log filename. Is there any way to turn off
> this behavior and just use the filename specified in log_filename? I'd like
> have all the log data written to a file like postgresql.log and let
> logrotate do the rotation.
Correct me if I'm wrong, but I think you're trying to redirect stderr.
Why not just use syslog? That's what I use and it works very nicely.
Here are the relevant bits from postgresql.conf (that aren't related
to log formatting and changed from the default).
log_destination = 'syslog'
syslog_facility = 'LOCAL1'
Just make sure you pipe the syslog facility to postgresql.log, and
then you can use logrotate.
Peter
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: pgsql-admin@postgresql.org
Cc: pjkoczan@gmail.com, dlowry@bju.edu
Subject: Re: way to turn off epochs in log_filename
In-Reply-To: <4544e0330710261325k708348fbm5c04eea44fd7ccc7@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