Thread: signal to send to postgres when log rolling

signal to send to postgres when log rolling

From
Christopher Kings-Lynne
Date:
Hi guys,

What is the correct signal (and number) that should be sent to postgres 
when you want to roll its logs?

I can't seem to see the answer...

Chris




Re: signal to send to postgres when log rolling

From
Bruce Momjian
Date:
Christopher Kings-Lynne wrote:
> Hi guys,
> 
> What is the correct signal (and number) that should be sent to postgres 
> when you want to roll its logs?
> 
> I can't seem to see the answer...

There isn't one.  You have to pipe into something like Apache's
rotatelogs or use syslog.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


Re: signal to send to postgres when log rolling

From
Tom Lane
Date:
Christopher Kings-Lynne <chriskl@familyhealth.com.au> writes:
> What is the correct signal (and number) that should be sent to postgres 
> when you want to roll its logs?

There is no log-rolling functionality in PG.  Use syslog, or pipe the
postmaster's output into something like Apache's logrotate program.
        regards, tom lane