Page 1 of 1

Problem connection to local network DB

PostPosted: Fri Apr 18, 2008 8:26 am
by bein
I have installed PT3 with PostgreSQL on 2 machines, with the goal of using only one DB from both machines ( its random if i use my laptop or office comp. to play.

And i dont seem to get this to work, they are both connected to the same LAN. When i try to connect to the database from my laptop i get the error message

" Unable to log in to datebase(template 1). Reason : could not connect to server : Connection refused (0x0000274D/ Is the server running on host "10.0.0.20" and accepting TCP/IP connections on port 5432?"

Yes the server is running on 10.0.0.20 and i have no internal firewall that should prevent any ports.

I hope any of you can assist me with this problem, might be an easy answer also since im a complete n00b with PostgreSQL :)

Thanks for any answers in advance

Ole

Re: Problem connection to local network DB

PostPosted: Fri Apr 18, 2008 7:23 pm
by APerfect10
By default, PostgreSQL only accepts connections on your localhost.

On your computer with the central PostgreSQL server, go Start->Programs->PostgreSQL->Configuration Files->Edit pg_hba.conf. Scroll to the bottom of this file and modify or add another line:

Code: Select all
# IPv4 local connections:
host    all         all         127.0.0.1/32          md5


So that it accepts 10.0.0.20

Best regards,

Derek

Re: Problem connection to local network DB

PostPosted: Sat Apr 19, 2008 7:10 am
by DK115
In this topic is all the information you need:

viewtopic.php?f=17&t=795

highfalutin