Re: - what protocol for an Internet postgres - Mailing list pgsql-general

From Nigel J. Andrews
Subject Re: - what protocol for an Internet postgres
Date
Msg-id Pine.LNX.4.21.0305162351010.3827-100000@ponder.fairway2k.co.uk
Whole thread Raw
In response to Re: - what protocol for an Internet postgres  (Network Administrator <netadmin@vcsn.com>)
Responses Re: - what protocol for an Internet postgres  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: - what protocol for an Internet postgres  (Network Administrator <netadmin@vcsn.com>)
List pgsql-general
On Fri, 16 May 2003, Network Administrator wrote:

> I use SSH all the time to tunnel shell and X-windows traffic.  I think I
> remember getting a local psql connection to a remote database going following
> the instruction s in section 3.8 of the Adminstrators guide but its been a
> little bit.
>
> If no one else response I'll take a wack at it and send in a step-by-step example.

Thanks for that, race you ;) (see below)

>
> As a note though, generally, I just SSH into the box that has the database and
> then run psql from there or open up pgaccess.

This is very odd. Over the space of 4 months I've tried this several times and
each time getting no where, including after reading the initial message in this
thread.

This evening I try again and as before get no where. However, I then go into
the firewall setup and disable one particular rule that opens all remote
hosts/ports for a particular service. I couldn't find one that matched the ssh
port on the remote test machine and this was the only candidate despite the
service name looking wrong for SSH and the associated program listed as a
Windows system folder one. I verify the normal ssh login and firewall
alerts. Try the tunneling, without having an open ssh session to the target
system, and unsurprisingly it fails. Then I login to the target system, after
finally remembering the password, and try the forwarding again and it works!

Basically the only thing different in my setup from earlier attempts is this
disabled firewall rule. I am very baffled but obviously in a position to write
a short piece on using SSH tunneling with SSH Communications software. I say
very short because there's little to say except the couple of setup steps and
may be some vague mutterings about firewalls [but quite what I don't know].

Sorry for the rambling, it is late here, and I'm baffled, amazed and wondering
how I'm going to explain to the two remote developers why they should try it
after all these months.

--
Nigel J. Andrews


>
> Quoting "Nigel J. Andrews" <nandrews@investsystems.co.uk>:
>
> > On Thu, 15 May 2003, Fernando Flores Prior wrote:
> >
> > > Nice !
> > >
> > > It works just great. This will be a fine asset for the thechdocs.
> > >
> > > -Fernando
> > >
> > >
> > > At 08:49 p.m. 14/05/2003 -0400, Matthew Nuzum wrote:
> > > >This thread got my curiosity going, so I endeavored to try to get it
> > working
> > > >and am happy to say that it was very easy to tunnel a postgresql
> > connection
> > > >over ssh.
> > > >
> > > >Here's what I did...
> > >
> >
> > Yes, smashing. Anyone got some similar destructions for SSH tunneling with
> > SSH
> > Communications Corp's (www.ssh.com) stuff. I've tried pointing and clicking
> > in
> > the appropiate dialog several times now and the best I can get is a notice
> > from
> > the firewall on the system that my test connection has connected to the
> > localhost but get a connection refused and don't see any network traffic out
> > to
> > the server. I can ssh into the server and get a shell (just to clarify that
> > point).
>



pgsql-general by date:

Previous
From: Jeff Eckermann
Date:
Subject: Re: context in plpgsql functions
Next
From: "Chris Palmer"
Date:
Subject: Re: priority on a process