From: | Josh Berkus <josh(at)agliodbs(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Fix PID file location? |
Date: | 2005-05-07 23:44:56 |
Message-ID: | 200505071644.56676.josh@agliodbs.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
Hey, folks,
I've noticed a problem with alternate PGDATA locations. Here's how to
reproduce:
On 8.0.2 on RHAS4:
1) Initdb a directory (on my system, /pgdata/pgdata)
2) Move the .conf files to an alternate location ( /etc/pgsql/)
3) Set $PGDATA to the alternate location ( /etc/pgsql )
4) Edit postgresql.conf to support this file arrangement
data_directory = '/pgdata/pgdata'
5) pg_ctl start PostgreSQL
6) pg_ctl stop PostgreSQL
7) Get an error: "No PID file found".
The problem seems to be that pg_ctl expects the PID file to be in $PGDATA, but
the file actually gets written by the postmaster to the actual data
directory. You can work around this by setting "external_pid_file", but this
then prevents you from using external_pid_file for another purpose.
Seems like it should be a relatively easy fix, although I'm not sure whether
the postmaster should write the PID to $PGDATA, or whether pg_ctl should be
made to look in the right place. Probably the latter.
--
--Josh
Josh Berkus
Aglio Database Solutions
San Francisco
From | Date | Subject | |
---|---|---|---|
Next Message | Tatsuo Ishii | 2005-05-08 00:08:39 | Re: Patch for collation using ICU |
Previous Message | Tom Lane | 2005-05-07 23:41:11 | Re: Patch for collation using ICU |
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2005-05-08 02:59:09 | Dealing with CLUSTER failures |
Previous Message | Heikki Linnakangas | 2005-05-07 21:08:43 | Re: [PATCHES] Cleaning up unreferenced table files |