Setting CLIENT_MIN_MESSAGES dynamically... - Mailing list pgsql-admin

From Eamonn Kent
Subject Setting CLIENT_MIN_MESSAGES dynamically...
Date
Msg-id 9146E3EBBFBCC94D95F95A1C4065348A837AEF@exch01.xsigo.com
Whole thread Raw
In response to Re: Why so long between archive calls?  ("Chris Hoover" <revoohc@gmail.com>)
List pgsql-admin

 

Hi,

 

My config file has the following setting:

log_min_messages = fatal

 

This setting assures that postgres logging is minimal.  However, I would like to change this setting dynamically – while our embedded application is running, without restarting postgres.  For example, in the case where the application appears to be running sluggishly, I would like to change this setting to debug1 so that I can collect detailed information.  The problem is the SET command applies only to the current session:

set log_min_messages='debug1';

 

Is there a way to accomplish this? 

 

Currently, we  have postgres generate a lot of debug messages (debug1) and then have syslog filter the messages as required.  This works since I can edit the syslog.conf and restart syslog independent of our application.  This is a less than ideal situation since we normally don’t want postgres producing lots of log data (wasting cpu)  since we require it only when doing debugging.

 

Thanks

 

Ike

 

pgsql-admin by date:

Previous
From: Tahir Tamba
Date:
Subject: PG installation on WinXP
Next
From: Miguel Arroz
Date:
Subject: How to check if VACUUM operations are working?