Search Postgresql Archives

Re: remote connection refused

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Usually, after what you've already confirmed, it's likely to be one of the following:

- check "listen_address" is set correctly in postgresql.conf. (try "listen_address = *" and restart postgres)
- check port 5432 is open on iptables. (service iptables status, netstat -a | grep 5432)

Cheers




From:        Yvon Thoraval <yvon.thoraval@xxxxxxxxx>
To:        "pgsql-general@xxxxxxxxxxxxxx" <pgsql-general@xxxxxxxxxxxxxx>,
Date:        19/11/2012 12:14
Subject:         remote connection refused
Sent by:        pgsql-general-owner@xxxxxxxxxxxxxx




I'd like to have a checklist upon what to do, what to investigate, when an external connection is refused.

if i connect by :

psql -h localhost -p 5432 -U yt mydb

it works as usual

however even locally but using the LAN address :

psql -h 192.168.0.20 -p 5432 -U yt mydb

i got a :
psql: could not connect to server: Connexion refusée
    Is the server running on host "192.168.0.20" and accepting
    TCP/IP connections on port 5432?


obviously I've verified by ping the computer is reachable.

something i suspect :
$ lal /var/run/postgresql
total 12
drwxrwsr-x  2 postgres postgres 140 nov.  19 09:53 .
drwxr-xr-x 26 root     root     900 nov.  19 09:45 ..
-rw-------  1 postgres postgres   6 nov.  19 09:53 9.1-main.pid
-rw-r--r--  1 postgres postgres   4 nov.  19 07:10 pgbouncer.pid
srwxrwxrwx  1 postgres postgres   0 nov.  19 09:53 .s.PGSQL.5432
-rw-------  1 postgres postgres  71 nov.  19 09:53 .s.PGSQL.5432.lock
srwxrwxrwx  1 postgres postgres   0 nov.  19 07:10 .s.PGSQL.6432


this the locked file :
.s.PGSQL.5432.lock

is that normal or not ?

something to say, i had a brutal shutdown due to over heating of my laptop recently.

on the pg_hba.conf i do have a bunch of IPV6 addresses allowing connection then i don't think the prob comes from here, but nevermind...

in such  a situation what is your checklist in order to find what I've missed ?
--
Yvon



=============================================

Romax Technology Limited
Rutherford House
Nottingham Science & Technology Park
Nottingham,
NG7 2PZ
England

Telephone numbers:
+44 (0)115 951 88 00 (main)

For other office locations see:
http://www.romaxtech.com/Contact
=================================
===============
E-mail: info@xxxxxxxxxxxxx
Website:
www.romaxtech.com
=================================

================
Confidentiality Statement
This transmission is for the addressee only and contains information that is confidential and privileged.
Unless you are the named addressee, or authorised to receive it on behalf of the addressee
you may not copy or use it, or disclose it to anyone else.
If you have received this transmission in error please delete from your system and contact the sender. Thank you for your cooperation.
=================================================

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux