pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Pgsql-PHP connection problem
2+ messages / 2 participants
[nested] [flat]

* Pgsql-PHP connection problem
@ 2005-09-28 01:10  Nirav Parikh <nirav.p@workskillsprofessionals.com.au>
  0 siblings, 1 reply; 2+ messages in thread

From: Nirav Parikh @ 2005-09-28 01:10 UTC (permalink / raw)
  To: pgsql-php

Hi Everyone,
 
I have setup new server running on Fedora Core 4. I am having problem connecting Php to Postgresql database. Now I also got couple of old server running same thing. I can connect through one of the existing server to this Postgresql database on new server. But Can't connect locally. 
 
This is the error message I get
 
"DB_Error Object ( [error_message_prefix] => [mode] => 1 [level] => 1024 [code] => -24 [message] => DB Error: connect failed [userinfo] => [nativecode=Warning: pg_pconnect() [function.pg-pconnect]: Unable to connect to PostgreSQL server: could not connect to server: Permission denied Is the server running on host "127.0.0.1" and accepting TCP/IP connections on port 5432? in /usr/share/pear/DB/pgsql.php on line 124] ** pgsql........"
 

File settings:
 
Pg_hba.conf file settings:
 
local  all    all                                                                              trust
host   all    all             127.0.0.1             255.255.255.255           trust

 
postgresql.conf file settings: 
 
listen_addresses = '*' 
port='5432'
 

Does anyone know how to resolve this? 
 
Thanks in advance.
 
Regards,
 
Nirav
 

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.8/113 - Release Date: 27/09/2005
 

^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Pgsql-PHP connection problem
@ 2005-09-28 02:16  John DeSoi <desoi@pgedit.com>
  parent: Nirav Parikh <nirav.p@workskillsprofessionals.com.au>
  0 siblings, 0 replies; 2+ messages in thread

From: John DeSoi @ 2005-09-28 02:16 UTC (permalink / raw)
  To: Nirav Parikh <nirav.p@workskillsprofessionals.com.au>; +Cc: pgsql-php


On Sep 27, 2005, at 9:10 PM, Nirav Parikh wrote:

> I have setup new server running on Fedora Core 4. I am having  
> problem connecting Php to Postgresql database. Now I also got  
> couple of old server running same thing. I can connect through one  
> of the existing server to this Postgresql database on new server.  
> But Can't connect locally.

Have you verified it is specifically a PHP problem? Can you connect  
with psql?

psql -h 127.0.0.1 dbname



John DeSoi, Ph.D.
http://pgedit.com/
Power Tools for PostgreSQL




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2005-09-28 02:16 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-09-28 01:10 Pgsql-PHP connection problem Nirav Parikh <nirav.p@workskillsprofessionals.com.au>
2005-09-28 02:16 ` John DeSoi <desoi@pgedit.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox