From sean.conlon@4expertsolutions.com Fri Jan 27 14:31:41 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 33E7F9DCB59 for ; Fri, 27 Jan 2006 10:31:41 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 89848-10 for ; Fri, 27 Jan 2006 10:31:44 -0400 (AST) Received: from svr4.postgresql.org (svr4.postgresql.org [66.98.251.159]) by postgresql.org (Postfix) with ESMTP id D140A9DCB4B for ; Fri, 27 Jan 2006 10:31:38 -0400 (AST) Received: from server2.4-am.com (server2.4-am.com [70.84.203.234]) by svr4.postgresql.org (Postfix) with ESMTP id 55A805AF173 for ; Fri, 27 Jan 2006 14:31:44 +0000 (GMT) Received: from [24.243.184.214] (helo=toshibauser) by server2.4-am.com with esmtpa (Exim 4.50) id 1F2UdZ-0008JP-FB for pgsql-jdbc@postgresql.org; Fri, 27 Jan 2006 08:31:41 -0600 From: "Sean" To: Subject: Postgres-JDBC question Date: Fri, 27 Jan 2006 08:31:41 -0600 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_000B_01C6231C.198D87C0" X-Mailer: Microsoft Office Outlook, Build 11.0.5510 Thread-Index: AcYjTmO6ZFvnRUV2SqCnZGuHin/COg== X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-SA-Exim-Connect-IP: 24.243.184.214 X-SA-Exim-Mail-From: sean.conlon@4expertsolutions.com X-SA-Exim-Scanned: No (on server2.4-am.com); SAEximRunCond expanded to false Message-Id: <20060127143144.55A805AF173@svr4.postgresql.org> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.001 required=5 tests=[HTML_MESSAGE=0.001] X-Spam-Score: 0.001 X-Spam-Level: X-Archive-Number: 200601/127 X-Sequence-Number: 14578 This is a multi-part message in MIME format. ------=_NextPart_000_000B_01C6231C.198D87C0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit I am using Hibernate to connect to my PostgreSQL (btw - I love) database, and can connect my app and the db when using localhost, but when I try to connect via an ip address, it blows up telling me that the connection was refused. I have set the postmaster to listen for TCP/IP connections, but still does not work. Any suggestions? Thanks, Sean ------=_NextPart_000_000B_01C6231C.198D87C0 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

I am using Hibernate to connect to my PostgreSQL (btw = – I love) database, and can connect my app and the db when using = localhost, but when I try to connect via an ip address, it blows up telling me that the connection was refused.  I have set the postmaster to listen for = TCP/IP connections, but still does not work.  Any suggestions? =

 

Thanks,

   Sean

------=_NextPart_000_000B_01C6231C.198D87C0-- From mark.lewis@mir3.com Fri Jan 27 18:41:54 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id A043C9DCA2E for ; Fri, 27 Jan 2006 14:41:54 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 34250-10 for ; Fri, 27 Jan 2006 14:41:54 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mir3-fs.mir3.com (mail.mir3.com [65.208.188.100]) by postgresql.org (Postfix) with ESMTP id 70EDF9DC851 for ; Fri, 27 Jan 2006 14:41:48 -0400 (AST) Received: mir3-fs.mir3.com 172.16.1.11 from 172.16.2.68 172.16.2.68 via HTTP with MS-WebStorage 6.0.6249 Received: from archimedes.mirlogic.com by mir3-fs.mir3.com; 27 Jan 2006 10:41:22 -0800 Subject: Re: Postgres-JDBC question From: Mark Lewis To: Sean Cc: pgsql-jdbc@postgresql.org In-Reply-To: <20060127143144.55A805AF173@svr4.postgresql.org> References: <20060127143144.55A805AF173@svr4.postgresql.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Organization: MIR3, Inc. Date: Fri, 27 Jan 2006 10:41:22 -0800 Message-Id: <1138387282.28241.45.camel@archimedes> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 (2.0.2-22) X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.121 required=5 tests=[AWL=0.120, UNPARSEABLE_RELAY=0.001] X-Spam-Score: 0.121 X-Spam-Level: X-Archive-Number: 200601/128 X-Sequence-Number: 14579 This usually means that you have allowed TCP/IP connections in postgresql.conf, but haven't added a rule allowing remote access in pg_hba.conf for anything other than localhost. A sample pg_hba.conf line to allow any host on the network to connect using MD5 password hashes would be: host all all 0.0.0.0 0.0.0.0 md5 -- Mark Lewis On Fri, 2006-01-27 at 08:31 -0600, Sean wrote: > I am using Hibernate to connect to my PostgreSQL (btw =E2=80=93 I love) > database, and can connect my app and the db when using localhost, but > when I try to connect via an ip address, it blows up telling me that > the connection was refused. I have set the postmaster to listen for > TCP/IP connections, but still does not work. Any suggestions?=20 >=20 > =20 >=20 > Thanks, >=20 > Sean=20 >=20 >=20 From philip@utiba.com Sat Jan 28 03:14:04 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 4212E9DC851 for ; Fri, 27 Jan 2006 23:14:04 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 60034-07 for ; Fri, 27 Jan 2006 23:14:08 -0400 (AST) Received: from svr4.postgresql.org (svr4.postgresql.org [66.98.251.159]) by postgresql.org (Postfix) with ESMTP id 44BC49DC84D for ; Fri, 27 Jan 2006 23:14:02 -0400 (AST) Received: from mail.utiba.com.au (eth2643.vic.adsl.internode.on.net [150.101.158.82]) by svr4.postgresql.org (Postfix) with ESMTP id A95025AF849 for ; Sat, 28 Jan 2006 03:14:06 +0000 (GMT) Received: from localhost (scan1.utiba.com.au [127.0.0.1]) by mail.utiba.com.au (Postfix) with ESMTP id 21DDE43EEE; Sat, 28 Jan 2006 14:14:01 +1100 (EST) Received: from mail.utiba.com.au ([127.0.0.1]) by localhost (scan1.utiba.com.au [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 16527-01; Sat, 28 Jan 2006 14:13:57 +1100 (EST) Received: from mail1.utiba.com (ser1 [192.168.0.1]) by mail.utiba.com.au (Postfix) with ESMTP id 5716043EE9; Sat, 28 Jan 2006 14:13:57 +1100 (EST) Received: from rotate-the-shield-harmonics.utiba.com (localhost [127.0.0.1]) by mail1.utiba.com (Postfix) with ESMTP id 47B8113ECBB; Sat, 28 Jan 2006 14:13:55 +1100 (EST) From: Philip Yarra Organization: Utiba Pty Ltd To: pgsql-jdbc@postgresql.org Subject: Re: Postgres-JDBC question Date: Sat, 28 Jan 2006 14:13:54 +1100 User-Agent: KMail/1.7.2 Cc: "Sean" References: <20060127143144.55A805AF173@svr4.postgresql.org> In-Reply-To: <20060127143144.55A805AF173@svr4.postgresql.org> X-enigma: Naturally a smoked function is living MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200601281413.54351.philip@utiba.com> X-Utiba-MailScanner-Information: Please contact the Systems Administrator at Utiba for more information X-Utiba-MailScanner: Found to be clean Utiba-MailScanner-MCPCheck: X-MailScanner-From: philip@utiba.com X-Virus-Scanned: amavisd-new at utiba.com.au X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0 required=5 tests=[none] X-Spam-Score: 0 X-Spam-Level: X-Archive-Number: 200601/129 X-Sequence-Number: 14580 On Sat, 28 Jan 2006 01:31 am, Sean wrote: > and can connect my app and the db when using localhost, but when I try to > connect via an ip address, it blows up telling me that the connection was > refused. I have set the postmaster to listen for TCP/IP connections, but > still does not work. Any suggestions? In postgresql.conf, the default config is to listen only on localhost IP address (probably listen_addresses will be set to default value and commented out). Change it so that is reads: listen_addresses = '*' and re-start the DB. As Mark mentioned, you may also want to review your pg_hba.conf file. Regards, Philip. -- "Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." - Brian W. Kernighan ----------------- Utiba Pty Ltd This message has been scanned for viruses and dangerous content by Utiba mail server and is believed to be clean. From gc@mnc.ch Mon Jan 30 09:51:51 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 1F2629DC834 for ; Mon, 30 Jan 2006 05:51:51 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 45041-05 for ; Mon, 30 Jan 2006 05:51:52 -0400 (AST) X-Greylist: delayed 00:11:53.272094 by SQLgrey- Received: from mail.mnc.ch (62-2-77-205.business.cablecom.ch [62.2.77.205]) by postgresql.org (Postfix) with ESMTP id D2CC39DC832 for ; Mon, 30 Jan 2006 05:51:47 -0400 (AST) Received: from localhost (localhost [127.0.0.1]) by mail.mnc.ch (Postfix) with ESMTP id A7E10A82C7; Mon, 30 Jan 2006 10:51:48 +0100 (CET) Received: from mail.mnc.ch ([127.0.0.1]) by localhost (mail.test.lan [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id 31920-02; Mon, 30 Jan 2006 10:51:47 +0100 (CET) Received: from meuh.mnc.lan (62-2-77-204.business.cablecom.ch [62.2.77.204]) by mail.mnc.ch (Postfix) with ESMTP id 5180EA82B4; Mon, 30 Jan 2006 10:51:47 +0100 (CET) Received: by meuh.mnc.lan (Postfix, from userid 1000) id 603E31835DB; Mon, 30 Jan 2006 10:51:43 +0100 (CET) To: Sean , pgsql-jdbc@postgresql.org Subject: Re: Postgres-JDBC question References: <20060127143144.55A805AF173@svr4.postgresql.org> <1138387282.28241.45.camel@archimedes> X-Hashcash: 1:20:060130:sean.conlon@4expertsolutions.com::3FV6KfkOKHGEQwAK:00000000000000000000000000000CTOj X-Hashcash: 1:20:060130:pgsql-jdbc@postgresql.org::PSOU7sNlYljVIOSc:0000000000000000000000000000000000002mIj From: Guillaume Cottenceau Date: 30 Jan 2006 10:51:43 +0100 In-Reply-To: <1138387282.28241.45.camel@archimedes> Message-ID: <873bj66o28.fsf@meuh.mnc.lan> Lines: 21 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: amavisd-new at mnc.ch X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.08 required=5 tests=[AWL=0.080] X-Spam-Score: 0.08 X-Spam-Level: X-Archive-Number: 200601/134 X-Sequence-Number: 14585 Mark Lewis writes: > This usually means that you have allowed TCP/IP connections in > postgresql.conf, but haven't added a rule allowing remote access in > pg_hba.conf for anything other than localhost. Sean - on Linux, you can check this with the following command: [root@meuh ~] netstat -ltpn Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:5432 0.0.0.0:* LISTEN 3310/postmaster ^^^ my postgres is listening on all addresses [...] tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 3259/master ^^^ my postfix is listening on localhost only -- Guillaume Cottenceau From Andrey.Myatluk@bercut.ru Wed Feb 1 09:01:29 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id E05E09DCC24 for ; Wed, 1 Feb 2006 05:01:29 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 96172-08 for ; Wed, 1 Feb 2006 05:01:30 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from guard.bercut.ru (guard.bercut.ru [195.144.243.254]) by postgresql.org (Postfix) with ESMTP id 280D89DCBA3 for ; Wed, 1 Feb 2006 05:01:26 -0400 (AST) Received: from guard.bercut.ru (root@localhost) by guard.bercut.ru (8.13.3/8.13.3) with SMTP id k1191SK3090564 for ; Wed, 1 Feb 2006 12:01:28 +0300 (MSK) (envelope-from Andrey.Myatluk@bercut.ru) Received: from master.office.bercut.ru (master.office.bercut.ru [192.168.5.12]) by guard.bercut.ru (8.13.4/8.13.1) with ESMTP id k1191Ss7090559 for ; Wed, 1 Feb 2006 12:01:28 +0300 (MSK) (envelope-from Andrey.Myatluk@bercut.ru) X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Subject: Re: Postgres-JDBC question Date: Wed, 1 Feb 2006 12:01:27 +0300 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [JDBC] Postgres-JDBC question Thread-Index: AcYlgt8Mldh8YeNJS7iT0Ktm8pY9tgBisy6A From: "Myatluk Andrey" To: Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by guard.bercut.ru id k1191Ss7090559 X-Anti-Virus: Kaspersky Anti-Virus for MailServers 5.5.2/RELEASE, bases: 01022006 #174246, status: clean X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.287 required=5 tests=[AWL=0.287] X-Spam-Score: 0.287 X-Spam-Level: X-Archive-Number: 200602/3 X-Sequence-Number: 14600 Guillaume, On my host if I run netstat I see the following: tcp 0 0 0.0.0.0:5432 0.0.0.0:* LISTEN 5557/postmaster tcp 0 0 :::5432 :::* LISTEN 5557/postmaster Do those mean that my database must be accessible from the outside? I have access from localhost processes, but my attempts to connect to the database with pgAdmin failed. Andrey -----Original Message----- From: pgsql-jdbc-owner@postgresql.org [mailto:pgsql-jdbc-owner@postgresql.org] On Behalf Of Guillaume Cottenceau Sent: Monday, January 30, 2006 12:52 PM To: Sean; pgsql-jdbc@postgresql.org Subject: Re: [JDBC] Postgres-JDBC question Mark Lewis writes: > This usually means that you have allowed TCP/IP connections in > postgresql.conf, but haven't added a rule allowing remote access in > pg_hba.conf for anything other than localhost. Sean - on Linux, you can check this with the following command: [root@meuh ~] netstat -ltpn Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:5432 0.0.0.0:* LISTEN 3310/postmaster ^^^ my postgres is listening on all addresses [...] tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 3259/master ^^^ my postfix is listening on localhost only -- Guillaume Cottenceau ---------------------------(end of broadcast)--------------------------- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq From tgl@sss.pgh.pa.us Wed Feb 1 14:32:24 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 50C019DC809 for ; Wed, 1 Feb 2006 10:32:24 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 58894-01 for ; Wed, 1 Feb 2006 10:32:28 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 20A6D9DC803 for ; Wed, 1 Feb 2006 10:32:21 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id k11EWFq5029727; Wed, 1 Feb 2006 09:32:15 -0500 (EST) To: "Myatluk Andrey" cc: pgsql-jdbc@postgresql.org Subject: Re: Postgres-JDBC question In-reply-to: References: Comments: In-reply-to "Myatluk Andrey" message dated "Wed, 01 Feb 2006 12:01:27 +0300" Date: Wed, 01 Feb 2006 09:32:15 -0500 Message-ID: <29726.1138804335@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.102 required=5 tests=[AWL=0.102] X-Spam-Score: 0.102 X-Spam-Level: X-Archive-Number: 200602/5 X-Sequence-Number: 14602 "Myatluk Andrey" writes: > On my host if I run netstat I see the following: > tcp 0 0 0.0.0.0:5432 0.0.0.0:* > LISTEN 5557/postmaster > tcp 0 0 :::5432 :::* > LISTEN 5557/postmaster > Do those mean that my database must be accessible from the outside? I > have access from localhost processes, but my attempts to connect to the > database with pgAdmin failed. Failed how, exactly? The netstat output shows that the postmaster is listening for connections from anyplace, so you have listen_addresses set properly ... but there are at least two other levels where an attempted connection might be blocked: kernel packet filtering, or the contents of pg_hba.conf. What error message are you getting *exactly*? regards, tom lane From tkanzakic@gmail.com Thu Feb 2 16:34:09 2006 X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id C90019DC81E for ; Thu, 2 Feb 2006 12:34:09 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 03627-01 for ; Thu, 2 Feb 2006 12:34:07 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey- Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.195]) by postgresql.org (Postfix) with ESMTP id D77D89DCAE1 for ; Thu, 2 Feb 2006 12:34:06 -0400 (AST) Received: by zproxy.gmail.com with SMTP id 14so453530nzn for ; Thu, 02 Feb 2006 08:34:06 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=KQodHO5kHBZb49yOlg+Ef209wqwv9B4kX9q07xyT1ODYAWuB+QOPHDuSFCWpF4a10RskfvJRD1b1xgJRKXjALUje0bmYdssQf59uWNoMZe9qsKlRClNgkreedJXdFzxvJZPpTYGGC4N0+EG6j0tm/gHkCAjkov0bcw39sCnwDUs= Received: by 10.36.46.20 with SMTP id t20mr754191nzt; Thu, 02 Feb 2006 08:34:06 -0800 (PST) Received: by 10.36.109.11 with HTTP; Thu, 2 Feb 2006 08:34:06 -0800 (PST) Message-ID: <651aa54b0602020834v1eb0c00j3c9b9e7b0408107a@mail.gmail.com> Date: Thu, 2 Feb 2006 21:34:06 +0500 From: Takeichi Kanzaki Cabrera To: Tom Lane Subject: Re: Postgres-JDBC question Cc: pgsql-jdbc@postgresql.org In-Reply-To: <29726.1138804335@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <29726.1138804335@sss.pgh.pa.us> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.08 required=5 tests=[AWL=0.080] X-Spam-Score: 0.08 X-Spam-Level: X-Archive-Number: 200602/14 X-Sequence-Number: 14611 Did you have some firewall running on your PC? Takeichi. On 2/1/06, Tom Lane wrote: > "Myatluk Andrey" writes: > > On my host if I run netstat I see the following: > > > tcp 0 0 0.0.0.0:5432 0.0.0.0:* > > LISTEN 5557/postmaster > > > tcp 0 0 :::5432 :::* > > LISTEN 5557/postmaster > > > Do those mean that my database must be accessible from the outside? I > > have access from localhost processes, but my attempts to connect to the > > database with pgAdmin failed. > > Failed how, exactly? The netstat output shows that the postmaster is > listening for connections from anyplace, so you have listen_addresses > set properly ... but there are at least two other levels where an > attempted connection might be blocked: kernel packet filtering, or the > contents of pg_hba.conf. What error message are you getting *exactly*? > > regards, tom lane > > ---------------------------(end of broadcast)--------------------------- > TIP 1: 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 >