From: | "Clodoaldo Pinto" <clodoaldo(dot)pinto(at)gmail(dot)com> |
---|---|
To: | "Robert Treat" <xzilla(at)users(dot)sourceforge(dot)net> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: php can't connect to postgresql server |
Date: | 2006-07-03 14:29:42 |
Message-ID: | a595de7a0607030729s65d9c6a0gf340b197f3934e43@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
2006/7/3, Robert Treat <xzilla(at)users(dot)sourceforge(dot)net>:
> On Monday 03 July 2006 09:25, Clodoaldo Pinto wrote:
> > php can't connect to postgresql server
> >
> > php error log message:
> >
> > PHP Warning: pg_connect() [<a
> > href='function.pg-connect'>function.pg-connect</a>]: Unable to connect
> > to PostgreSQL server: could not connect to server: Permission
> > denied\n\tIs the server running on host "127.0.0.1" and
> > accepting\n\tTCP/IP connections on port 5432?
> >
> > php connection string:
> >
> > $conn_string = "hostaddr=127.0.0.1 port=5432 dbname=dbname
> > user=username password=password";
> >
> > Also tried host=localhost
> >
>
> It needs to be host, not hostaddr.
Changed to host=localhost as I had already done before with the same
results. From the php manual:
"The currently recognized parameter keywords are: host, hostaddr,..."
> > What else should I check? I am out of ideas.
> >
>
> Make sure that your postgresql.conf "listen_addresses" is properly set,
What do you mean by properly set? What I had already post is not properly set?:
listen_addresses = '127.0.0.1,xx.xx.xxx.xx'
> make sure you dont have a firewall setting that is blocking connections, the
> default firewall settings on FC boxes are notorious for blocking pg.
Opened the 5432 port in the firewall and still the same problem.
Clodoaldo
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2006-07-03 15:03:28 | Re: [JDBC] Is what I want possible and if so how? |
Previous Message | Martijn van Oosterhout | 2006-07-03 14:08:57 | Re: How serious are these problems? |