Re: Changing default ../data/ directory

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: Rich Shepard <rshepard(at)appl-ecosys(dot)com>
Cc: pgsql-general <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Changing default ../data/ directory
Date: 2020-01-04 16:37:49
Message-ID: CAMkU=1xd1PP=8yBg0e5ZAQ+KO_tJP=yv=6eMitA8yGAwJ4TCQQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sat, Jan 4, 2020 at 10:20 AM Rich Shepard <rshepard(at)appl-ecosys(dot)com>
wrote:

>
> The PGDATA environment variable used to be used for this (but I never did
> get it satisfactorily working).

PGDATA should work fine if you always start the server directly. But if
you sudo or su to another user, they likely won't inherit your environment
variables. And if you use some kind of start-up script, they will likely
override it. How do you start and stop PostgreSQL?

> I'm sure it's in the manual yet I'm unsure just where to start reading.
>

If you are using start-up scripts that come with some installation package,
then the details are up to the packager. The PostgreSQL manual is of
little use in knowing what the packager decided to do. It will describe
what the pieces are, but not how they got assembled together.

Cheers,

Jeff

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message George Neuner 2020-01-04 17:38:23 Re: Changing default ../data/ directory
Previous Message Rich Shepard 2020-01-04 16:27:25 Re: Changing default ../data/ directory