Thread: Windows ODBC and a Router obstacle?
I am trying to connect to my PG 8.2 db server from MS Access from a remote location.
I had configured PG to trust all connections from this location.
i.e. in PG_HBA.conf I added a line containing:
host all all ip-address/32 trust
(and restarted the server)
But I cannot get a connection.
Could there be a problem with the local router in this location? What should I look for in the router set-up?
JPD657
On 03/08/2011 10:01 AM, Joseph Doench wrote: > I am trying to connect to my PG 8.2 dbserverfrom MS Accessfroma remote > location. > > I had configured PG to trust all connections from this location. > > i.e. in PG_HBA.confI added a line containing: > > host all all ip-address/32 trust > > (and restarted the server) > > But I cannot get a connection. > > Could there be a problem with the local router in this location? What > should I look for in the router set-up? > > JPD657 > A couple of questions: What does the Postgres log show when you try to connect? Do you have another way to connect to the Postgres server from the Access machine and have you tried it? Specifically have you tried using psql to connect? -- Adrian Klaver adrian.klaver@gmail.com
I see this in the PG log: unexpected EOF on client connection could not receive data from client: No connection could be made because the target machine actively refused it. JPD657 > I am trying to connect to my PG 8.2 dbserverfrom MS Accessfroma remote > location. > > I had configured PG to trust all connections from this location. > > i.e. in PG_HBA.confI added a line containing: > > host all all ip-address/32 trust > > (and restarted the server) > > But I cannot get a connection. > > Could there be a problem with the local router in this location? What > should I look for in the router set-up? > > JPD657 > A couple of questions: What does the Postgres log show when you try to connect? Do you have another way to connect to the Postgres server from the Access machine and have you tried it? Specifically have you tried using psql to connect? -- Adrian --
On Tuesday, March 08, 2011 4:25:31 pm Joseph Doench wrote: > I see this in the PG log: > > unexpected EOF on client connection > could not receive data from client: No connection could be made because the > target machine actively refused it. > > JPD657 So Access/ODBC is getting out but the Postgres server cannot get back to the Windows machine. First I do not use Windows much any more, so my suggestions will be general. I would start by taking a look at the Windows Firewall program and see if is blocking incoming connections for non standard ports. What sort of router are we talking about, home type(Netgear,Linksys,etc) or enterprise type? I have not a home type block returning data from an established connection, mainly because they are fairly open. -- Adrian Klaver adrian.klaver@gmail.com
The router is a 'home' type... less than 2 or 3 years old... has 802.11n I'll have to take a look into it tomorrow. > I see this in the PG log: > > unexpected EOF on client connection > could not receive data from client: No connection could be made because the > target machine actively refused it. > > JPD657 So Access/ODBC is getting out but the Postgres server cannot get back to the Windows machine. First I do not use Windows much any more, so my suggestions will be general. I would start by taking a look at the Windows Firewall program and see if is blocking incoming connections for non standard ports. What sort of router are we talking about, home type(Netgear,Linksys,etc) or enterprise type? I have not a home type block returning data from an established connection, mainly because they are fairly open. -- Adrian
Hi, Is your router configured with NAT maybe? If yes, the source IP of your packets is the one of the router, not the remotelocation. Try trusting everything from everywhere in your pg_hba.conf file, just to make sure it's a network problem... ------------------------------------------------------------- Attik System web : http://www.attiksystem.ch Philippe Lang phone : +41 26 422 13 75 rte de la Fonderie 2 gsm : +41 79 351 49 94 1700 Fribourg twitter: @philippelang pgp : http://keyserver.pgp.com > -----Message d'origine----- > De : pgsql-odbc-owner@postgresql.org [mailto:pgsql-odbc- > owner@postgresql.org] De la part de Joseph Doench > Envoyé : mardi 8 mars 2011 19:02 > À : pgsql-odbc@postgresql.org > Objet : [ODBC] Windows ODBC and a Router obstacle? > > I am trying to connect to my PG 8.2 db server from MS Access from a > remote location. > > I had configured PG to trust all connections from this location. > > i.e. in PG_HBA.conf I added a line containing: > > host all all ip-address/32 trust > > (and restarted the server) > > But I cannot get a connection. > > Could there be a problem with the local router in this location? What > should I look for in the router set-up? > > JPD657
Attachment
Problem resolved. DOH ! Overlooked a silly mistake - a firewall setting. Thanks for you time, JPD -----Original Message----- From: pgsql-odbc-owner@postgresql.org [mailto:pgsql-odbc-owner@postgresql.org] On Behalf Of Philippe Lang Sent: Tuesday, March 22, 2011 10:51 AM To: Joseph Doench; pgsql-odbc@postgresql.org Subject: Re: [ODBC] Windows ODBC and a Router obstacle? Hi, Is your router configured with NAT maybe? If yes, the source IP of your packets is the one of the router, not the remotelocation. Try trusting everything from everywhere in your pg_hba.conf file, just to make sure it's a network problem... ------------------------------------------------------------- Attik System web : http://www.attiksystem.ch Philippe Lang phone : +41 26 422 13 75 rte de la Fonderie 2 gsm : +41 79 351 49 94 1700 Fribourg twitter: @philippelang pgp : http://keyserver.pgp.com > -----Message d'origine----- > De : pgsql-odbc-owner@postgresql.org [mailto:pgsql-odbc- > owner@postgresql.org] De la part de Joseph Doench Envoyé : mardi 8 > mars 2011 19:02 À : pgsql-odbc@postgresql.org Objet : [ODBC] Windows > ODBC and a Router obstacle? > > I am trying to connect to my PG 8.2 db server from MS Access from a > remote location. > > I had configured PG to trust all connections from this location. > > i.e. in PG_HBA.conf I added a line containing: > > host all all ip-address/32 trust > > (and restarted the server) > > But I cannot get a connection. > > Could there be a problem with the local router in this location? What > should I look for in the router set-up? > > JPD657