Turning on/off the logfile

Поиск
Список
Период
Сортировка
Искать

Turning on/off the logfile

От:
Gerald Gutierrez <pozix@home.com>
Дата:

PostgreSQL spits out logging information to stdout and stderr which can 
then be piped to a file to act as a "log file". Is there a way to get 
PostgreSQL to enable/disable this output without restarting the server? 
Currently I have to edit /etc/rc.d/init.d/postgresql to run postgresql 
with >mylogfile or >/dev/null, and restart the server.

If there isn't an ability to do this, I think I'll whip up a little script 
that will read stderr/stdin but listen to signals and turn the output on or 
off.

Thanks.

Gerald.

Re: Turning on/off the logfile

От:
Andrew Sullivan <andrew@libertyrms.com>
Дата:
On Fri, Jun 01, 2001 at 08:24:32PM -0700, Gerald Gutierrez wrote:
> 
> If there isn't an ability to do this, I think I'll whip up a little script 
> that will read stderr/stdin but listen to signals and turn the output on or 
> off.

I think you can't turn this on & off on the fly, but I uncovered a
little program the other day which might work (I haven't tried it
yet), called flog.  See .

-- 
----
Andrew Sullivan                               87 Mowat Avenue 
Liberty RMS                           Toronto, Ontario Canada
                               M6K 3E3
                                         +1 416 646 3306 x110

FAQ