From: | Brock Henry <brock(dot)henry(at)gmail(dot)com> |
---|---|
To: | tgl(at)sss(dot)pgh(dot)pa(dot)us |
Cc: | pgsql-admin(at)postgresql(dot)org |
Subject: | Re: Stream pg_dumpall directly from CentOS7 to Red Hat server |
Date: | 2024-07-29 02:43:08 |
Message-ID: | CAAFiYLEKWa8fCWWctFOFMSuQivomUec+66WQ7rziVTwrgKmv0A@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
👍
Brock reacted via Gmail
<https://www.google.com/gmail/about/?utm_source=gmail-in-product&utm_medium=et&utm_campaign=emojireactionemail#app>
On Mon, 29 July 2024, 12:11 pm Tom Lane, <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Brock Henry <brock(dot)henry(at)gmail(dot)com> writes:
> > I personally would create an ssh tunnel for port 5432, if ssh was open
> but
> > 5432 was not.
>
> +1, but I think your example is not quite right:
>
> > ssh -L 5432:localhost:5432 redhat_ip_address
> > pg_dumpall -U postgres | psql -h localhost -U postgres
>
> If you have a local PG server, it's probably using 5432 so that ssh
> can't bind to that. I think you want something like
>
> ssh -L 5433:localhost:5432 redhat_ip_address
> pg_dumpall -U postgres | psql -h localhost -p 5433 -U postgres
>
> where "5433" can be any locally-unused port number (caution: untested;
> the ssh arguments may still not be quite right).
>
> regards, tom lane
>
From | Date | Subject | |
---|---|---|---|
Next Message | Zaid Shabbir | 2024-07-29 03:12:42 | Re: Stream pg_dumpall directly from CentOS7 to Red Hat server |
Previous Message | Tom Lane | 2024-07-29 02:11:54 | Re: Stream pg_dumpall directly from CentOS7 to Red Hat server |