azure-cli icon indicating copy to clipboard operation
azure-cli copied to clipboard

az postgres flexible-server execute ssl

Open ferronsw opened this issue 3 years ago • 5 comments

I'm running the az postgres flexible-server execute command, but it won't connect:

ERROR: Unable to connect to flexible server: connection to server at "<name>.postgres.database.azure.com" (10.194.1.4), port 5432 failed: FATAL: password authentication failed for user "admin_sutin" connection to server at "<name>.postgres.database.azure.com" (10.194.1.4), port 5432 failed: FATAL: no pg_hba.conf entry for host "10.192.253.4", user "admin_sutin", database "postgres", no encryption

It says no encryption, but Azure postgres flexible-server has ssl by default. The command doesn't allow to enable ssl. This is strange right?

Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ferronsw avatar Sep 02 '22 09:09 ferronsw

route to CXP team

yonzhan avatar Sep 02 '22 11:09 yonzhan

@ferronsw I am able to connect to postgres flexible server without any issues. Have you added the correct ip address of your machine to postgres flexible server ? Also, please try updating rdms-connect extension using az extension update --name "rdbms-connect" and try again.

SaurabhSharma-MSFT avatar Sep 09 '22 17:09 SaurabhSharma-MSFT

@ferronsw Please let me know if you still have any questions else, we will be proceeding with the closure of this issue.

SaurabhSharma-MSFT avatar Sep 12 '22 22:09 SaurabhSharma-MSFT

I think it's because I use VNET integration for the postgres instance. The machine I run the PowerShell command from can connect to the server. But maybe the command isn't executed from this machine?

I already have the latest version of rdms-connect.

ferronsw avatar Sep 13 '22 07:09 ferronsw

@ferronsw ok.. let me check with a server having vnet integrations.

SaurabhSharma-MSFT avatar Sep 23 '22 16:09 SaurabhSharma-MSFT

@ferronsw Are you able to connect to your flexible server using psql ?

SaurabhSharma-MSFT avatar Sep 28 '22 00:09 SaurabhSharma-MSFT

@SaurabhSharma-MSFT Yes I'm able to connect using psql.

ferronsw avatar Sep 28 '22 07:09 ferronsw

@ferronsw I suggest you to please open a Azure Support Ticket so that an engineer can check further investigate this issue. In case you have any limitations in your support plan to open support ticket please let me know.

SaurabhSharma-MSFT avatar Sep 28 '22 22:09 SaurabhSharma-MSFT

@ferronsw We will now proceed to close this thread. If there are further questions regarding this matter, please reopen it and we will gladly continue the discussion.

SaurabhSharma-MSFT avatar Oct 26 '22 19:10 SaurabhSharma-MSFT