From: | Richard Huxton <dev(at)archonet(dot)com> |
---|---|
To: | "Thomas LeBlanc" <thomasatiem(at)hotmail(dot)com>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: Loggin SQL Statements from JBOSS/JDBC |
Date: | 2003-11-14 18:11:04 |
Message-ID: | 200311141811.04456.dev@archonet.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Friday 14 November 2003 17:08, Thomas LeBlanc wrote:
> Where are the log files written?
Usually somewhere in /var/log/ but it depends on your startup script. If
you're on RedHat Linux and using the RPMs then your startup script is
/etc/init.d/postgresql and it seems to redirect to /dev/null (around line
157).
Personally, I like to log via syslog. In your postgresql.conf set:
syslog = 2
syslog_facility = 'LOCAL0'
syslog_ident = 'postgres'
In /etc/syslog.conf add:
# Postgresql logfile
local0.* /var/log/postgresql
touch /var/log/postgresql
Add /var/log/postgresql to /etc/logrotate.d/syslog so you logs get recyled and
then:
service syslog restart
service postgresql restart
These are for RedHat Linux, but the process will be similar on most unix-like
systems.
--
Richard Huxton
Archonet Ltd
From | Date | Subject | |
---|---|---|---|
Next Message | Rajesh Kumar Mallah | 2003-11-14 18:13:26 | Re: DOMAIN usability |
Previous Message | btober | 2003-11-14 17:55:16 | Re: Conservation of OIDs |