Re: PostgreSQL Streaming replication on two diff networks

From: Scott Whitney <scott(at)journyx(dot)com>
To: Pierre Ochsenbein <pierre(dot)ochsenbein(at)acceleris(dot)ch>, "pgsql-admin(at)lists(dot)postgresql(dot)org" <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: PostgreSQL Streaming replication on two diff networks
Date: 2018-06-05 13:19:46
Message-ID: BYAPR11MB2663EE57770AEF7BEAF396E3A7660@BYAPR11MB2663.namprd11.prod.outlook.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Sure, but you need to be able to reach it.

You need to be able to ping/ssh between the 2 hosts first.

________________________________
From: Pierre Ochsenbein <pierre(dot)ochsenbein(at)acceleris(dot)ch>
Sent: Tuesday, June 5, 2018 8:14 AM
To: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: PostgreSQL Streaming replication on two diff networks

Dear securtiy support,

I want to deploy a PostgreSQL Cluster with streaming replication, but I have a problem..

We have two VMs in two different data-centers with two different network.

It's possible to made a streaming replication with two different network?

My output :

vm01:10.1.24.13

vm02:10.0.2.67

On my slave (vm02) :

I can't make a pg_basebackup..

pg_basebackup: could not connect to server: could not connect to server: No route to host
Is the server running on host "10.1.24.13" and accepting
TCP/IP connections on port 5432?
pg_basebackup: removing data directory "/var/lib/pgsql/10/data"

[root(at)vm02 ~]# tcptraceroute 10.1.24.13 5432
traceroute to 10.1.24.13 (10.1.24.13), 30 hops max, 60 byte packets
1 gateway (192.168.1.1) 0.375 ms 0.304 ms 0.282 ms
2 169.254.95.213 (169.254.95.213) 0.261 ms 0.241 ms 0.198 ms
3 10.0.2.1 (10.0.2.1) 1.761 ms 2.725 ms 3.449 ms
4 172.16.9.41 (172.16.9.41) 1.141 ms 172.16.9.33 (172.16.9.33) 1.190 ms 172.16.9.41 (172.16.9.41) 1.642 ms
5 172.16.9.50 (172.16.9.50) 0.388 ms 172.16.9.54 (172.16.9.54) 0.367 ms 172.16.9.62 (172.16.9.62) 0.430 ms
6 10.1.23.4 (10.1.23.4) 0.227 ms 0.388 ms 0.345 ms
7 10.1.23.4 (10.1.23.4) 0.298 ms !X 0.384 ms !X 0.326 ms !X

pg_hba.conf file on my master :

# replication privilege.
local replication all peer
host replication all 127.0.0.1/32 ident
host replication all ::1/128 ident
host replication replicate 10.0.2.67/32 scram-sha-256

Thank you so much for your help

Best regards,

Pierre

[Acceleris]

Acceleris AG | cloudifying IT
Pierre Ochsenbein | Technical Consultant
Schosshaldenstrasse 85 | CH-3006 Bern
T : +41 31 911 33 22 | F : +41 31 911 62 63
pierre(dot)ochsenbein(at)acceleris(dot)ch | www.acceleris.ch

Acceleris Offices are in :
Bern | Zurich | Renens | Bucharest

[Acceleris]

Disclaimer

This message possibly contains confidential data or items of information. It is intended solely for the rightful recipient. If you should have received the message wrongfully, it is not permitted to disclose the e-mail message or its contents to third parties, to copy or use it. We would respectfully request you to destroy the message with the exclusion of any reproduction and to notify this to the originator by e-mail. Thank you very much.

Journyx, Inc.
7600 Burnet Road #300
Austin, TX 78757
www.journyx.com

p 512.834.8888
f 512-834-8858

Do you receive our promotional emails? Click here <http://journyx.com/communication-preferences> or visit http://journyx.com/communication-preferences to unsubscribe.

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Shreeyansh Dba 2018-06-05 13:22:09 Re: PostgreSQL Streaming replication on two diff networks
Previous Message Pierre Ochsenbein 2018-06-05 13:14:20 PostgreSQL Streaming replication on two diff networks