Re: Postgres access using PHP

From: John Poltorak <jp(at)eyup(dot)org>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Postgres access using PHP
Date: 2001-01-14 23:29:21
Message-ID: 20010114232921.F85@eyup.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Sun, Jan 14, 2001 at 10:27:57PM +0000, John Poltorak wrote:
>
> I am trying to access a Postgres database using PHP from a Web page
> and it doesn't work.
>
> Could anyone shed any light on the problem?
>
> This is the error I get - which looks like an authentication problem:-
>
> Unable to connect to PostgreSQL server: FATAL 1: SetUserId: user 'root' is not in 'pg_shadow'
>
> What have I overlooked in setting up Postgres for Web access?

Many thanks to everyone who suggested my Web server was running as 'root'
and this was the cause of the problem.

I'd just like to point out that I'm running Postgres, PHP4, and Xitami
all under OS/2, which is a single-user OS, and the USER variable does
not get set automatically.

I have set the this variable to POSTGRES before starting Xitami,
just to make sure I can get everything going and it works fine now,

So, thank you all.

--
John

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Ron Chmara 2001-01-14 23:32:12 Re: Postgres access using PHP
Previous Message Chris 2001-01-14 22:58:02 Re: Postgres access using PHP