Setting logfile location with pg_ctl and postgres.conf

From: Frank Joerdens <frank(at)joerdens(dot)de>
To: pgsql-general(at)postgresql(dot)org
Subject: Setting logfile location with pg_ctl and postgres.conf
Date: 2001-01-27 22:48:46
Message-ID: 20010127234846.A27451@rakete.joerdens.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I am using beta3 and am setting my runtime options via
data/postgresql.conf, which works just fine:

log_connections = on
log_pid = true
log_timestamp = true
fsync = off
max_connections = 256
sort_mem = 8192
shared_buffers = 2048
tcpip_socket = on
unix_socket_directory = '/usr/db/pgsql/sockdir'

When starting with

/usr/db/pgsql/bin/pg_ctl -D /usr/db/pgsql/data

I don't see how you can set the log file to something like

/usr/db/pgsql/log/postgresql_db.log

From the docs you can see how to use the syslog facility via
postgresql.conf but it's not really obvious how you use both
the config file and pg_ctl with a logfile location like the above.

That I've only managed to do like:

/usr/db/pgsql/bin/postmaster -i -d 2 -B 2048 -N 256 -o '-F -S 8192'\
>>/usr/db/log/postgresql_db.log 2>&1 &

Is there a 'proper' way to accomplish this or do I simply create my own
startscript?

Regards, Frank

BTW: How do you see runtime options passed to the postmaster via the
config file? The command

pg_ctl status

only shows those options that were passed on
the command line.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Mitch Vincent 2001-01-27 23:04:51 varchar => int
Previous Message Oliver Elphick 2001-01-27 22:23:16 Re: How do I solve this efficiently?