Re: could not connect

From: Jean-Michel POURE <jmpoure(at)translationforge(dot)com>
To: "Richard Pijnenburg" <richard(dot)mail(at)softhome(dot)net>, pgadmin-support(at)postgresql(dot)org
Subject: Re: could not connect
Date: 2002-04-21 07:32:28
Message-ID: 200204210932.28878.jmpoure@translationforge.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

Le Samedi 20 Avril 2002 17:25, Richard Pijnenburg a écrit :
> I run PostgreSQL version 7.1.3 on my Redhat linux server.
> When I try to connect with pgadmin I get the next error message :
> An error has occured in pgadmin II : frmConnect.cmdConnect_click:
> Number: -2147467258
> Description: Could not connect to server; Could not connect to remote
> socket.
> I've configured the postgresql server so that I can use it true the
> network.
> Can any one help me?

Dear Richard,

For security reasons, TCP_IP socket connexion is not enabled by default in
PostgreSQL. Try these steps:

1) Open /var/lib/pgsql/data/postgresql.conf
uncomment line "tcpip_socket = true"
This will enable TCPIP sockets for PHP and ODBC connexions.

2) List your Windows client IP in pg_hba.conf
For example for IP 192.168.1.101 :
host all 192.168.0.101 255.255.255.0 password

You can also replace "password" with "trust" if you whish to connect without
password direcly from pgAdmin2 (If so, create a user with pgAdmin2 instead of
step 4. After that, replace "trust" with "passwor", restart PostgreSQL).

3) Restart PostgreSQL
postgres(at)localhost>exit (to return to root user).
root(at)localhost>service postgresql restart
Connect from pgAdmin2. This should work

4) Create an administrator user in pgsql
From your Linux server :
root(at)locahost> su -postgres
postgres(at)localhost> pgsql template1;
# CREATE USER foo PASSWORD 'bar' CREATEDB CREATEUSER;
# \q

5) More information can be found on :
http://www.postgresql.org/idocs <- Beautifull interactive documentation.
http://techdocs.postgresql.org <- technical docs and tips.

Do not hesitate to come back to us in case of problem.
PostgreSQL is a beautiful database, have fun.

Cheers,
Jean-Michel POURE

In response to

Browse pgadmin-support by date

  From Date Subject
Next Message Jean-Michel POURE 2002-04-21 08:04:55 Re: Older version?
Previous Message Andy Lewis 2002-04-20 17:51:22 Older version?