pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
min duration logging
2+ messages / 2 participants
[nested] [flat]

* min duration logging
@ 2011-10-11 18:23 AA <araskoktas@gmail.com>
  2011-10-11 19:52 ` Re: min duration logging Steve Crawford <scrawford@pinpointresearch.com>
  0 siblings, 1 reply; 2+ messages in thread

From: AA @ 2011-10-11 18:23 UTC (permalink / raw)
  To: pgsql-admin

hey all
trying to find non optimized queries and want to use this logging feature,
however postgresql seems to write every query to log.

my conf is as follows

log_destination = 'csvlog'
logging_collector = on
log_directory = '/usr/local/pgb/pg_log'
log_rotation_size = 100MB
#syslog_facility = 'LOCAL0'
#syslog_ident = 'postgres'
#silent_mode = off
#client_min_messages = debug1
#log_min_messages = warning
#log_min_error_statement = error
log_min_duration_statement = 450
#debug_print_parse = off
#debug_print_rewritten = off
#debug_print_plan = off
#debug_pretty_print = on
#log_checkpoints = off
#log_connections = off
#log_disconnections = off
log_duration = on
#log_error_verbosity = default
#log_hostname = off
#log_line_prefix = ''
#log_lock_waits = off
#log_statement = 'all'
#log_temp_files = -1
#log_timezone = unknown

^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: min duration logging
  2011-10-11 18:23 min duration logging AA <araskoktas@gmail.com>
@ 2011-10-11 19:52 ` Steve Crawford <scrawford@pinpointresearch.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Steve Crawford @ 2011-10-11 19:52 UTC (permalink / raw)
  To: AA <araskoktas@gmail.com>; +Cc: pgsql-admin

On 10/11/2011 11:23 AM, AA wrote:
> hey all
> trying to find non optimized queries and want to use this logging 
> feature, however postgresql seems to write every query to log.
>
> my conf is as follows...
>
> log_min_duration_statement = 450
> ...

What durations are showing in the log? Are lots/all of the queries you 
run longer than 450ms?


> #log_statement = 'all'
>

I don't know what the config looked like beforehand but did you reload 
PostgreSQL after changing it? You can check the current running settings 
with "show all;"

Cheers,
Steve




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2011-10-11 19:52 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2011-10-11 18:23 min duration logging AA <araskoktas@gmail.com>
2011-10-11 19:52 ` Steve Crawford <scrawford@pinpointresearch.com>

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