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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
elhak47
New Member

Power bi service refresh via on premises data gateway

Hello, 
 
I tried to establish a connection between the on-premises data gateway and my MongoDB database on a local Kubernetes cluster, which is exposed via pod port forwarding. The Power BI desktop refresh is working fine, but when I schedule a refresh on the Power BI service, it sometimes runs successfully, but most of the time, it returns the following errors:
1/ An established connection was aborted by the software in your host machine."
2/error copying from remote stream to local connection:
3/  An existing connection was forcibly closed by the remote host. 
I tried to restart the on premises data gateway software and deactivate firewall but it did not fix the problem.

po.png

 

3 REPLIES 3
vs_7
Continued Contributor
Continued Contributor

HI @elhak47 ,

try to refresh from server side.

elhak47
New Member

Thank you @vs_7 for your help,
but i checked all the above solutions, and it's clear that's not a mongodb connection issue neither   pod port forwarding , the firewall i tried to deactivate it but still same bugs,  i use the same connection to update my reports locally on powerbi desktop, and even with powerbi service  via on prem data gateway it works fine manually today but the problem is when i schedule refreshing datasets,  most of the time, it returns the previous errors 

vs_7
Continued Contributor
Continued Contributor

Hi @elhak47 ,

try below steps

 

  1. Verify network connectivity: Ensure that there is a stable network connection between the Power BI service and your local Kubernetes cluster. Check if there are any network interruptions or latency issues that could cause the connection to be dropped or closed.

  2. Check port forwarding configuration: Review the port forwarding configuration for your MongoDB database on the Kubernetes cluster. Make sure that the port forwarding is correctly set up and that the exposed port is accessible from the Power BI service. Verify that the port forwarding is still active and hasn't been disrupted.

  3. Confirm firewall settings: Double-check the firewall settings on your local machine and Kubernetes cluster. Ensure that the necessary ports are open and not blocked by the firewall. Consult the documentation for your specific firewall software or system to correctly configure the firewall rules.

  4. Update the on-premises data gateway: Ensure that you are using the latest version of the on-premises data gateway software. Check for any available updates and install them to ensure you have the most recent bug fixes and enhancements.

  5. Check MongoDB configuration: Review the configuration of your MongoDB database and verify that it is properly configured to accept connections from the on-premises data gateway. Check the MongoDB logs for any relevant error messages that could shed light on the issue.

  6. Test connectivity outside Power BI: Try connecting to your MongoDB database from a different client or tool outside of Power BI, such as a MongoDB client or command-line tool. This can help isolate whether the issue is specific to Power BI or a more general connectivity problem.

  7. Review Power BI service logs: In the Power BI service, check the logs and error messages for the scheduled refresh operation. Look for any specific error codes or messages that can provide insights into the cause of the issue. This can help in troubleshooting or provide information to Microsoft Support if further assistance is required.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.