Re: Can't login/createdb

From: Doug McNaught <doug(at)wireboard(dot)com>
To: joe(at)jwebmedia(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Can't login/createdb
Date: 2001-12-05 22:34:03
Message-ID: m37ks1e1pg.fsf@belphigor.mcnaught.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Joe Koenig <joe(at)jwebmedia(dot)com> writes:

> Alright, I've got that taken care of now. Thanks to everyone who
> responded. Next dumb question - I need to be able to connect to postgres
> from PHP - I know that I need to start it up with the '-i' option, but I
> need to make sure it starts up with that option when the machine
> reboots.

Are you sure? If PHP uses libpq than it should be able to use Unix
domain sockets (on the same machine of course).

> I found the 010.pgsql.sh file and it says to edit
> $PG_DATA/postgresql.conf - so I went to my data dir and uncommented the
> line that said 'tcpip_socket = false' and changed it to true. When
> trying to connect from PHP, I get an error stating:
>
> Warning: Unable to connect to PostgreSQL server: pqReadData() -- backend
> closed the channel unexpectedly. This probably means the backend
> terminated abnormally before or while processing the request.

Well, this is either a backend crash (bad) or possibly an
authentication failure. What do your logs say? Are there any core
files in $PGDATA?

-Doug
--
Let us cross over the river, and rest under the shade of the trees.
--T. J. Jackson, 1863

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Doug McNaught 2001-12-05 22:35:37 Re: Sparc v Intel
Previous Message Bruce Momjian 2001-12-05 22:26:35 Re: DEBUG messages