pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Evan Rempel <erempel@uvic.ca>
To: pgsql-admin@lists.postgresql.org
Subject: Re: Separate log for a specfic database
Date: Wed, 28 Feb 2018 10:17:14 -0800
Message-ID: <04ec6db0-2983-1366-ccd6-84e9bbdb21c3@uvic.ca> (raw)
In-Reply-To: <CAKFQuwZK0J04WOixt=PEw5QsM=wLw_OMq6x8S8X9K1JTJjccOg@mail.gmail.com>
References: <00e501d3b0ba$7d302830$77907890$@1nar.com.tr>
	<CAKFQuwZK0J04WOixt=PEw5QsM=wLw_OMq6x8S8X9K1JTJjccOg@mail.gmail.com>

On 02/28/2018 10:05 AM, David G. Johnston wrote:
> On Wednesday, February 28, 2018, Ertan Küçükoğlu 
> <ertan.kucukoglu@1nar.com.tr <mailto:ertan.kucukoglu@1nar.com.tr>> wrote:
>
>     Hello,
>
>     I am using PostgreSQL 9.6.6 on Debian 9 Stretch system. Installed
>     using
>     apt-get.
>     I wonder if I can have two log files. One for complete database
>     server and
>     another for one specific database in the server.
>     I have already read below link, but cannot understand if that is
>     possible,
>     or how.
>     https://www.postgresql.org/docs/9.6/static/runtime-config-logging.html
>     <https://www.postgresql.org/docs/9.6/static/runtime-config-logging.html;
>
>
> When it says:
>
> " This parameter can only be set in the postgresql.conf file or on the 
> server command line. "
>
> It is scoped to the cluster and all databases therein.  To do what you 
> desire you would need to put the unique database into its own cluster.
>
> David J.

That is not exactly true.

Logging could be set up to use syslog and if the database name is in the 
log lines
then some filtering and routing of hose messages could go into their own 
files.

This would require a mature syslog environment but it is possible.

Evan.





view thread (5+ messages)  latest in thread

Message-ID: <04ec6db0-2983-1366-ccd6-84e9bbdb21c3@uvic.ca>
Permalink:  ../04ec6db0-2983-1366-ccd6-84e9bbdb21c3@uvic.ca/
Also on:    postgresql.org/message-id/04ec6db0-2983-1366-ccd6-84e9bbdb21c3@uvic.ca

 · 

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: pgsql-admin@postgresql.org
  Cc: erempel@uvic.ca, pgsql-admin@lists.postgresql.org
  Subject: Re: Separate log for a specfic database
  In-Reply-To: <04ec6db0-2983-1366-ccd6-84e9bbdb21c3@uvic.ca>

* 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