public inbox for [email protected]  
help / color / mirror / Atom feed
From: Peter Eisentraut <[email protected]>
To: P Kapat <[email protected]>
Cc: [email protected]
Subject: Re: Incomplete online documentation on conecting via ssh tunnels
Date: Thu, 20 Nov 2008 10:26:39 +0200
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

P Kapat wrote:
> The relevant documentations are (replace 8.3 by 8.2 or 8.1 or...):
> http://www.postgresql.org/docs/8.3/static/ssh-tunnels.html
> 
> The concerned command is:
> client$ ssh -L 3333:foo.com:5432 [email protected]
> 
>>From the discussion on the novice list, I came to the conclusion that
> the above command works only when listen_addresses = '*' OR
> listen_addresses = 'a.b.c.d'
> (where a.b.c.d is the IP of foo.com; other IPs can be present too)  is
> set in postgresql.conf.
> 
> But in most cases, for security reason, the server is quarantined
> within localhost by setting: listen_addresses = 'localhost'.
> 
> In this case, the ssh tunnel does not work. The correct command is:
> client$ ssh -L 3333:localhost:5432 [email protected]
> OR
> client$ ssh -L 3333:127.0.0.1:5432 [email protected]

You are absolutely correct.  Someone already pointed this out 
independently, and the 8.4devel documentation has much better 
information on this:

http://developer.postgresql.org/pgdocs/postgres/ssh-tunnels.html



view thread (4+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: Incomplete online documentation on conecting via ssh tunnels
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox