Re: Problem with pg_hba.conf file in Postgres 7.3

From: April Carvalho <acarvalh(at)brave(dot)cs(dot)uml(dot)edu>
To: Oliver Elphick <olly(at)lfix(dot)co(dot)uk>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, <pgsql-novice(at)postgresql(dot)org>, Dan MacNeil <omacneil(at)brave(dot)cs(dot)uml(dot)edu>
Subject: Re: Problem with pg_hba.conf file in Postgres 7.3
Date: 2004-01-26 21:30:54
Message-ID: Pine.LNX.4.44.0401261621560.26011-100000@brave.cs.uml.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Yes, that would help. <feeling stupid>

The files in question were the ones referenced in pg_hba.conf:

host db1 @db1_users 10.0.0.0 255.255.255.0 md5

There are actually several lines (and several user lists) in this file.
Files like @db1_users, were in /etc/postgresql/, since pg_hba.conf was
there. This made sense at the time, because, according to the postgres
docs, they should be in the same folder as pg_hba.conf.
However, the debian package has $PGDATA/pg_hba.conf has a link
to /etc/postgresql/pg_hba.conf. Postgres is probably expecting
pg_hba.conf to be in $PGDATA, and Debain expects it in /etc/postgresql.
If I knew nothing of Debian, perhaps this wouldn't have happened.

Funny huh?

Btw, the $PGDATA variable *was* set after all, but just for user postgres.

Thanks for all your help.

April

On Mon, 26 Jan 2004, Oliver Elphick wrote:

> On Mon, 2004-01-26 at 20:18, April Carvalho wrote:
> > Btw, thanks for all the help. :-)
> >
> > I think that permissions are ok, since it was working fine when
> > the files were moved; it would still be broken if the perms were
> > not right.
>
> Where were the files when it didn't work, and where did you move them
> to?
>
> > However $PGDATA was not set, assuming that the debconf (the debian
> > package configuration program) had already set it properly.
>
> In the environment of the 'postgres' login, it should be set. This is
> the user under which the postmaster is (should be) run. If it weren't
> set, the postmaster couldn't start, because it wouldn't know where to
> find the database. If an ordinary user needs it set, he should source
> /etc/postgresql/postgresql.env in his .bashrc or other startup script.
>
> --
> Oliver Elphick Oliver(dot)Elphick(at)lfix(dot)co(dot)uk
> Isle of Wight, UK http://www.lfix.co.uk/oliver
> GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839 932A 614D 4C34 3E1D 0C1C
> ========================================
> "Wash me thoroughly from mine iniquity, and cleanse me
> from my sin. For I acknowledge my transgressions; and
> my sin is ever before me. Against thee, thee only,
> have I sinned, and done this evil in thy sight..."
> Psalms 51:2-4
>

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Oliver Elphick 2004-01-26 21:53:32 Re: Problem with pg_hba.conf file in Postgres 7.3
Previous Message Jeff Eckermann 2004-01-26 20:53:22 Re: Database creation