Re: connecting To PostgreSQL - Getting Error

Re: connecting To PostgreSQL - Getting Error

am 06.08.2002 16:17:30 von Dan Wilson

That port is not standard. Are you sure that is the correct port to connect
with? Also, make sure you are using the tcpip_socket. Check your
postgresql.conf file and uncomment and turn on the tcpip_socket option.

Your other option is to just connect using the local socket (which is more
secure anyway). You can do this by just leaving of the host option in your
connection string.

-Dan

Quoting Riyaz@umapinc.com:

> Hello All,
> I am running Postgresql on a linux Qube and trying to connect to it
> using PHP. But it is giving me the following error:
>
> Warning: Unable to connect to PostgreSQL server: connectDB() -- connect()
> failed:
> Connection refused Is the postmaster running (with -i) at 'localhost' and
> accepting connections on TCP/IP port '5583'? in
> /home/groups/smarttools/web/testpg2.php on line 21
>
> I don't think I am using Unix sockets as I can connect to the database on
> psql monitor without -i option and without specifying the port number.
>
> Any tips on solving this?
>
> Also in what files are connectDB - - connect() functions stored?
>
> Thanks,
> Riyaz.

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

connecting To PostgreSQL - Getting Error

am 06.08.2002 17:18:13 von Riyaz

This is a multipart message in MIME format.
--=_alternative 004E700D85256C0D_=
Content-Type: text/plain; charset="us-ascii"

Hello All,
I am running Postgresql on a linux Qube and trying to connect to it
using PHP. But it is giving me the following error:

Warning: Unable to connect to PostgreSQL server: connectDB() -- connect() failed:
Connection refused Is the postmaster running (with -i) at 'localhost' and
accepting connections on TCP/IP port '5583'? in /home/groups/smarttools/web/testpg2.php on line 21

I don't think I am using Unix sockets as I can connect to the database on
psql monitor without -i option and without specifying the port number.

Any tips on solving this?

Also in what files are connectDB - - connect() functions stored?

Thanks,
Riyaz.
--=_alternative 004E700D85256C0D_=
Content-Type: text/html; charset="us-ascii"



Hello All,

    I am running Postgresql on a linux Qube and trying to connect to it using PHP. But it is giving me the following error:



Warning: Unable to connect to PostgreSQL server: connectDB() -- connect() failed: Connection refused Is the postmaster running (with -i) at 'localhost' and accepting connections on TCP/IP port '5583'? in /home/groups/smarttools/web/testpg2.php on line 21



I don't think I am using Unix sockets as I can connect to the database on psql monitor without -i option and without specifying the port number.



Any tips on solving this?



Also in what files are connectDB - - connect() functions stored?



Thanks,

Riyaz.
--=_alternative 004E700D85256C0D_=--