Postgresql replication from Azure to a non-managed instance

Eugene Zheganin 1 Reputation point
2022-02-17T15:09:36.667+00:00

I have a azure postgresql managed instance, it was created when Flexible one wasn't available, so it seems to be what MS calls Single. I want to replicate the DB outside the cloud for development purposes. Currently I see no way to do this, because:

  • when it comes to streaming replication, there's no way to modify pg_hba.conf to add replication entries there. Modifying connection security entries just seem to create ordinay host entries, so pg_basebackup gets the FATAL: no pg_hba.conf entry for replication connection from host error.
  • when it comes to the logical replication, Single server doen't have the pglogical extension.

So... am I really out of options ?

Azure Database for PostgreSQL
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. GeethaThatipatri-MSFT 29,387 Reputation points Microsoft Employee
    2022-02-17T16:35:08.337+00:00

    Hi, @Eugene Zheganin Welcome to the Microsoft forum, thank you for posting your query.
    Any chance that you can migrate to flex?
    About single, the only option is logical decoding check Here.

    Workaround for hba as described in the docs:
    if you are running Postgres 9.5 or 9.6, and use public network access, add the firewall rule to include the public IP address of the client from where you will run the logical replication. The firewall rule name must include _replrule. For example, test_replrule. To create a new firewall rule on the server, run the az postgres server firewall-rule create command.

    Please let us know if this information helps

    Regards
    Geetha


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.