Azure Database for PostgreSQL Error: connection failed: could not receive data from server

ericOnline 21 Reputation points
2024-07-23T21:29:30.86+00:00

When trying to connect Azure Data Studio to an Azure Database for Postgresql flexible server, I receive the error:

connection failed: could not receive data from server: Socket is not connected (0x00002749/10057)
could not send SSL negotiation packet: Socket is not connected (0x00002749/10057)

User's image I'm on a corporate network but Azure Storage Explorer and VS Code work just fine.

Thank you

Azure Database for PostgreSQL
{count} votes

1 answer

Sort by: Most helpful
  1. ShaktiSingh-MSFT 15,421 Reputation points
    2024-07-24T06:26:49.2333333+00:00

    Hi ericOnline •,

    Welcome to Microsoft Q&A forum.

    As I understand, you are trying to connect to Azure Database for PostgreSQL Flexible server using Azure Data Studio with Entra Auth.

    Could you please let us know if this is the first time you are trying to login using Azure Data Studio and it failed? Or it was working fine earlier and this happened for the first time?

    Also, please follow the documentation here https://learn.microsoft.com/en-us/azure/postgresql/single-server/how-to-configure-sign-in-azure-ad-authentication for configuration of users and roles needed for Login to server depending on if it is for Single User or A Group Member.

    Note

    Authenticating a user through Microsoft Entra ID does not give the user any permissions to access objects within the Azure Database for PostgreSQL database. You must grant the user the required permissions manually.

    If you have tried to migrate users to Entra ID based Auth, then consider two cases mentioned here: https://learn.microsoft.com/en-us/azure/postgresql/single-server/how-to-configure-sign-in-azure-ad-authentication#migrating-existing-postgresql-users-to-microsoft-entra-id-based-authentication

    Hope this helps. Let us know your finding and result.

    Thanks

    0 comments No comments

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.