pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Default data directory
4+ messages / 4 participants
[nested] [flat]

* Default data directory
@ 2008-09-05 18:44 Carol Walter <walterc@indiana.edu>
  2008-09-05 19:11 ` Re: Default data directory Tom Lane <tgl@sss.pgh.pa.us>
  2008-09-05 21:21 ` Re: Default data directory Scott Marlowe <scott.marlowe@gmail.com>
  0 siblings, 2 replies; 4+ messages in thread

From: Carol Walter @ 2008-09-05 18:44 UTC (permalink / raw)
  To: pgsql-admin; +Cc: Dave Cole <daedcole@indiana.edu>

Hello,

We're building a test box for our webmaster to play in.  It needs to  
have the same config as his production box.  The postgres default  
data directory doesn't match the location of the data directory  
location on the production box.  The postgresql.conf file has the  
line that says that it changes the default data location commented  
out.  Is there somewhere else that postgres can get this information?

I can't figure out how the Postgres that's running on the production  
web server knows where to look for its data.

Thanks,
Carol



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

* Re: Default data directory
  2008-09-05 18:44 Default data directory Carol Walter <walterc@indiana.edu>
@ 2008-09-05 19:11 ` Tom Lane <tgl@sss.pgh.pa.us>
  1 sibling, 0 replies; 4+ messages in thread

From: Tom Lane @ 2008-09-05 19:11 UTC (permalink / raw)
  To: Carol Walter <walterc@indiana.edu>; +Cc: pgsql-admin@postgresql.org, Dave Cole <daedcole@indiana.edu>

Carol Walter <walterc@indiana.edu> writes:
> I can't figure out how the Postgres that's running on the production  
> web server knows where to look for its data.

Generally the location of the data directory is determined by a -D
switch on the postmaster command line, or by setting the PGDATA
environment variable in the script that launches the postmaster.

Setting it in the configuration file would be circular logic,
except in the uncommon sort of configuration where the config file
doesn't live in the data directory (in which case the -D switch
only indicates where the config files are).

			regards, tom lane



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

* Re: Default data directory
  2008-09-05 18:44 Default data directory Carol Walter <walterc@indiana.edu>
@ 2008-09-05 21:21 ` Scott Marlowe <scott.marlowe@gmail.com>
  2008-09-05 21:38   ` Re: Default data directory Ben Kim <bkim@tamu.edu>
  1 sibling, 1 reply; 4+ messages in thread

From: Scott Marlowe @ 2008-09-05 21:21 UTC (permalink / raw)
  To: Carol Walter <walterc@indiana.edu>; +Cc: pgsql-admin@postgresql.org, "Dave Cole" <daedcole@indiana.edu>

On Fri, Sep 5, 2008 at 12:44 PM, Carol Walter <walterc@indiana.edu> wrote:
> Hello,
>
> We're building a test box for our webmaster to play in.  It needs to have
> the same config as his production box.  The postgres default data directory
> doesn't match the location of the data directory location on the production
> box.  The postgresql.conf file has the line that says that it changes the
> default data location commented out.  Is there somewhere else that postgres
> can get this information?
>
> I can't figure out how the Postgres that's running on the production web
> server knows where to look for its data.

We don't quite have enough information to really troubleshoot this.
What OS, and how was pg installed in each if they're different.

If the webmaster needs a sandbox like production, then I would assume
the two OSes are the same, right?



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

* Re: Default data directory
  2008-09-05 18:44 Default data directory Carol Walter <walterc@indiana.edu>
  2008-09-05 21:21 ` Re: Default data directory Scott Marlowe <scott.marlowe@gmail.com>
@ 2008-09-05 21:38   ` Ben Kim <bkim@tamu.edu>
  0 siblings, 0 replies; 4+ messages in thread

From: Ben Kim @ 2008-09-05 21:38 UTC (permalink / raw)
  To: Carol Walter <walterc@indiana.edu>; +Cc: pgsql-admin

> Is there somewhere else that postgres can get this information?
> I can't figure out how the Postgres that's running on the production web
> server knows where to look for its data.

Could it be the compile time setting? I guess you can try

     # pg_config --configure

and the --prefix=... will likely be where the "data" sits?


Regards,

Ben Kim



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


end of thread, other threads:[~2008-09-05 21:38 UTC | newest]

Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2008-09-05 18:44 Default data directory Carol Walter <walterc@indiana.edu>
2008-09-05 19:11 ` Tom Lane <tgl@sss.pgh.pa.us>
2008-09-05 21:21 ` Scott Marlowe <scott.marlowe@gmail.com>
2008-09-05 21:38   ` Ben Kim <bkim@tamu.edu>

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