Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
D17
Regular Visitor

Help with Power BI Desktop Connection to PostgreSQL on Amazon RDS via SSH - Connection Failed Error

Hi everyone,

I'm trying to connect Power BI Desktop to a PostgreSQL database hosted on Amazon RDS using an SSH tunnel. However, I keep encountering the following error:

 

"An error happened while reading data from the provider: 'A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond'"

 

Here’s what I’ve done so far:

  1. I changed the Public Accessibility setting on the Amazon RDS instance to "Yes" to make it accessible externally.
  2. I've verified the security group settings to allow inbound connections on the PostgreSQL port (5432) from my machine’s IP.
  3. I've tested connecting to the database using pgAdmin and it works fine.
  4. I’m using SSH tunneling because the database is in a private subnet.

 

Despite all this, Power BI fails to connect. Could anyone suggest the steps I might be missing or need to recheck? Are there any specific configurations in Power BI Desktop, RDS, or SSH that I need to focus on?

Thanks in advance for your help!

 

 

1 ACCEPTED SOLUTION
v-yohua-msft
Community Support
Community Support

Hi, @D17 

Make sure your SSH tunnel is configured correctly. You can use PuTTY or OpenSSH to create tunnels. Also check your security group settings again to make sure that inbound traffic from your local machine IP address to port 5432 is allowed. At the same time, make sure that there are no local firewall settings blocking the connection.
Amazon RDS for PostgreSQL enforces SSL connections. Make sure Power BI is configured to use SSL when you try to connect. 

 

 

Power BI requires an Npgsql driver to connect to PostgreSQL. Make sure the driver is installed and configured correctly on your machine. You can check this post:

vyohuamsft_0-1727401929098.png

Solved: Connecting to PostgresSQL hosted on AWS RDS? - Microsoft Fabric Community


When setting up a connection in Power BI, use the appropriate connection string format.  You can refer to the following post:

vyohuamsft_1-1727401958275.png

Solved: Connect Desktop Power BI to AWS RDS postgreSQL - Microsoft Fabric Community

 

How to Get Your Question Answered Quickly

Best Regards

Yongkang Hua

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-yohua-msft
Community Support
Community Support

Hi, @D17 

Make sure your SSH tunnel is configured correctly. You can use PuTTY or OpenSSH to create tunnels. Also check your security group settings again to make sure that inbound traffic from your local machine IP address to port 5432 is allowed. At the same time, make sure that there are no local firewall settings blocking the connection.
Amazon RDS for PostgreSQL enforces SSL connections. Make sure Power BI is configured to use SSL when you try to connect. 

 

 

Power BI requires an Npgsql driver to connect to PostgreSQL. Make sure the driver is installed and configured correctly on your machine. You can check this post:

vyohuamsft_0-1727401929098.png

Solved: Connecting to PostgresSQL hosted on AWS RDS? - Microsoft Fabric Community


When setting up a connection in Power BI, use the appropriate connection string format.  You can refer to the following post:

vyohuamsft_1-1727401958275.png

Solved: Connect Desktop Power BI to AWS RDS postgreSQL - Microsoft Fabric Community

 

How to Get Your Question Answered Quickly

Best Regards

Yongkang Hua

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.