pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andy Shellam (Mailing Lists) <andy.shellam-lists@mailnetwork.co.uk>
To: jing han <jing_han_66@yahoo.com>
To: pgsql-interfaces@postgresql.org
Subject: Re: where postgres 8.1.8 log messages go
Date: Tue, 27 Feb 2007 15:57:09 +0000
Message-ID: <45E454D5.9070301@mailnetwork.co.uk> (raw)
In-Reply-To: <710787.90612.qm@web53511.mail.yahoo.com>
References: <710787.90612.qm@web53511.mail.yahoo.com>

Don't forget to copy back to the list - Reply To All is your friend ;)

This is my configuration:

log_directory = '/var/log/endeavour/pgsql'              # Directory 
where log files are written

Note the single quotes, not double - this could be your problem.

Also note that /var/log/messages is a file, not a directory.  PostgreSQL 
will write it's own log files.
If you want to use a specific log file, use log_filename in conjunction 
with log_directory - but note that syslog uses /var/log/messages so 
don't use that or it'll get syslog confused.
You can log to syslog as well, if that's what you want to do.  Read that 
manual page some more.

I would also not put the log files in /var/log - at least make a 
subdirectory like /var/log/pgsql.
I've known built-in Linux rotate and compress scripts to play havoc with 
PostgreSQL by rotating and compressing it's logs while it's trying to 
use them, when they're in /var/log.

Andy.

jing han wrote:
> Hi Andy,
>
> Thanks for the  information. I tried to add
>
> log_destination = "/var/log/messages"
>
> into postgresql.conf, then I started database server, I found that db server throwed the following error message:
>
> FATAL:  syntax error in file "/var/nm2/postgresql.conf" line 130, near token """
>
> Can you tell me the syntax for this?
>
> The document said that " This option can be set at server start or in the          postgresql.conf configuration file.", If set at server start,
> what is the option for this pramater? (for example: -D  is for the database file directory)
>
> Thank you for your help.
>
>
> jing
> ---- Original Message ----
> From: Andy Shellam (Mailing Lists) <andy.shellam-lists@mailnetwork.co.uk>
> To: jing han <jing_han_66@yahoo.com>
> Cc: pgsql-interfaces@postgresql.org
> Sent: Tuesday, February 27, 2007 9:32:56 AM
> Subject: Re: [INTERFACES] where postgres 8.1.8 log messages go
>
> Wherever you want them to.
> In your postgresql.conf file, review the "logging" section.
>
> The following will help you:
>
> http://www.postgresql.org/docs/8.1/static/runtime-config-logging.html
>
> Andy.
>
> jing han wrote:
>   
>> Hello,
>>
>> I have a question about postgres log messages. postgres 7.2.3 log messages go to /var/log/messages file, postgres 8.1.8 log messages do not go to /var/log/messages, so where they go?
>>
>> Any feedback will be appreciated.
>>
>>
>> jing
>>
>>
>>
>>
>>  
>> ____________________________________________________________________________________
>> Want to start your own business?
>> Learn how on Yahoo! Small Business.
>> http://smallbusiness.yahoo.com/r-index
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 7: You can help support the PostgreSQL project by donating at
>>
>>                 http://www.postgresql.org/about/donate
>>   
>>     
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: Don't 'kill -9' the postmaster
>
>
>
>
>
>  
> ____________________________________________________________________________________
> Any questions? Get answers on any topic at www.Answers.yahoo.com.  Try it now.
>
> !DSPAM:37,45e45146103008115917888!
>
>
>   


-- 
Andy Shellam
NetServe Support Team

the Mail Network
"an alternative in a standardised world"

p: +44 (0) 121 288 0832/0839
m: +44 (0) 7818 000834

view thread (3+ messages)

Message-ID: <45E454D5.9070301@mailnetwork.co.uk>
Permalink:  ../45E454D5.9070301@mailnetwork.co.uk/
Also on:    postgresql.org/message-id/45E454D5.9070301@mailnetwork.co.uk

 · 

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-interfaces@postgresql.org
  Cc: andy.shellam-lists@mailnetwork.co.uk, jing_han_66@yahoo.com
  Subject: Re: where postgres 8.1.8 log messages go
  In-Reply-To: <45E454D5.9070301@mailnetwork.co.uk>

* 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