How to migrate database users from Azure PostgreSQL single server to flexible server?

Pratik 20 Reputation points
2024-05-06T18:47:09.7233333+00:00

Hello team,

I was using the migration tool provided in Azure portal to migrate databases from PostgreSQL single server to flexible server.The migration itself was successful and I could see my database and data in the flexible server.

The issue I am facing is the database users present in the single server are not migrated to the flexible server.

While going through help + support I found this statement "The tool takes care of the migration of data and schema. It doesn't migrate managed service features such as server parameters, connection security details, firewall rules, users, roles and permissions. In the later part of the document, we point you to docs that can help you perform the migration of users, roles and firewall rules from single server to flexible server." but I was not able to find where this information is present.

Where can I find the steps to migrate my users securely from single server to flexible server? Does microsoft provide some way to do it from Azure portal or using script securely?

Azure Database for PostgreSQL
{count} votes

Accepted answer
  1. Oury Ba-MSFT 19,581 Reputation points Microsoft Employee
    2024-05-08T16:13:10.7133333+00:00

    Pratik

    Any configuration to migrate the db users to the target db.? Any other configuration that needs to be done pre-migration for db users.?

    The migration service supports user roles migration when the source is Azure Database for PostgreSQL Single Server. However, this feature is currently disabled for PostgreSQL version 16 servers **(**which includes Flexible Server). In other words, if you’re migrating from Single Server to Flexible Server, the user roles won’t be automatically migrated.

    Option 1: The feature will be made available In June. You can choose to wait until this feature is enabled for PostgreSQL 16.

    Option 2: Alternatively, you can choose to migrate to a lower version, such as PostgreSQL version 15. Once the migration is completed, you can then use our major version upgrade to upgrade the server to version 16. However, before proceeding with this option, I recommend checking our documentation for further guidance and validate the limitations Major version upgrades in Azure Database for PostgreSQL - Flexible Server.

     hope that helps

    Regards,

    Oury

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

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.