From: | "Nick Fankhauser" <nickf(at)ontko(dot)com> |
---|---|
To: | "daniel m" <dmeil(at)acer-access(dot)com>, <pgsql-admin(at)postgresql(dot)org> |
Subject: | Re: Postmaster environment variables |
Date: | 2002-06-28 15:15:38 |
Message-ID: | NEBBLAAHGLEEPCGOBHDGMELPFDAA.nickf@ontko.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Daniel-
When you restart postmaster, the process isn't getting this env variable
because it isn't defined in .profile for your postgres user or in a shell
file that .profile executes.
On Debian Linux, you could set this in /var/lib/postgres/.profile or
/etc/postgresql/postgresql.env
Regards,
-Nick
--------------------------------------------------------------------------
Nick Fankhauser nickf(at)ontko(dot)com Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko & Co. Software Consulting Services http://www.ontko.com/
> -----Original Message-----
> From: pgsql-admin-owner(at)postgresql(dot)org
> [mailto:pgsql-admin-owner(at)postgresql(dot)org]On Behalf Of daniel m
> Sent: Thursday, June 27, 2002 9:23 PM
> To: pgsql-admin(at)postgresql(dot)org
> Subject: [ADMIN] Postmaster environment variables
>
>
> I am trying to relocate my database, as per instructions in the manual:
>
> Under user postgres :
>
> sh-2.04$ PGDATA2=/home/postgres/data
> sh-2.04$ export PGDATA2
> sh-2.04$ echo $PGDATA2
> /home/postgres/data
>
> I stop the postmaster and :
> sh-2.04$ /usr/lib/postgresql/bin/initlocation PGDATA2
> The location will be initialized with username "postgres".
> This user will own all the files and must also own the server process.
>
> Fixing permissions on pre-existing directory /home/postgres/data
> Fixing permissions on pre-existing directory /home/postgres/data/base
>
> initlocation is complete. (...)
>
> I restart the postmaster and :
>
> sh-2.04$ createdb planifgr -D 'PGDATA2'
> ERROR: Postmaster environment variable 'PGDATA2' not set
> createdb: database creation failed
>
> although :
>
> sh-2.04$ echo $PGDATA2
> /home/postgres/data
>
> I even tried to set the variable from within the scripts (debian distr.)
> that start the backend (etc/init.d/postgresql). Same response.
>
> Where is the variable?
>
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: Have you searched our list archives?
>
> http://archives.postgresql.org
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | Ray Ontko | 2002-06-28 15:44:02 | Re: Are statistics gathered on function indexes? |
Previous Message | Fouad Fezzi | 2002-06-28 15:12:14 | Re: Postmaster environment variables |