[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: PostgerSQL 7.3 packages for woody



On Sat, 2002-12-14 at 02:57, eric lin wrote:
> Oliver Elphick wrote:
...
> > If that is OK, try (as user postgres):
> > 
> >         $ pg_encoding 2
> > 
> > If that fails, the search path is wrong; /etc/postgresql/postgresql.env
> > (from package postgresql-client) needs to be sourced by postgres's
> > .profile
> 
> this step I failed, both as root and end-user,
> so how should I modify?(at /etc/postgresql/postgresql.env  ? or anywhere 
> to do anything?)

You need a file in the home directory of postgres to load its
environment.

Become user postgres

Use your favourite editor, such as vi, to edit the profile for postgres:

        $ vi ~postgres/.profile

The contents of the file should look like this:

        . /etc/postgresql/postmaster.conf
        PATH=/bin:/usr/bin:/usr/lib/postgresql/bin
        PGDATA=${POSTGRES_DATA:-/var/lib/postgres/data}
        PGLIB=/usr/lib/postgresql/lib
        export PGLIB PGDATA

After you have done that, logout of postgres and log into it again.  You
should then be able to do:

        $ pg_encoding 2
        
If that works, log out of postgres, become superuser and retry the
installation of postgresql:

        # dpkg --pending --configure


-- 
Oliver Elphick <olly@lfix.co.uk>
LFIX Limited



Reply to: