Forum Discussion
Connecting to PostgreSQL: "No such host is known"
I can connect to all of our PostgreSQL databases in Power BI Desktop but none of them are accessible when publishing the reports. They all come back with invalid credentials and when I type in the credentials it says the following.
What am I missing here?
4 Replies
- AnonymousNot applicable
Hi Anonymous ,
Please try to install gateway for connect your dataset to on-premise data source.
Please try below steps:
1. install a gateway: personal/standard type, that according to your connection type
2. configure the gateway
3. set the data source for gateway in service
4. can view report in service
For more details, you can read related document: On-premises data gateways documentation | Microsoft Learn , On-premises data gateway - Power BI | Microsoft Learn , Install an on-premises data gateway | Microsoft Learn , Use the on-premises data gateway app | Microsoft Learn , Manage an on-premises data gateway | Microsoft Learn
Best regards,
Community Support Team_ Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. - Ivan4ever84Frequent Visitor
I have the same issue while I am tryng to sign the credential in PBI Service to connecting to Azure PostgreSQL.
The Gateway it is not necessary and cannot be the solution because both the source (PBI Service and Azure PostgreSQL) are in Microsoft Cloud and not on-premises.Does anyone know the solution? Thanks!
- AnonymousNot applicable
We managed to solve the issue. When we had a further look at the error message (when expanding it) it said that we had to use "Npgsql v4.0.10 or Earlier". So, we installed it and it worked. Just note that you have to select "NpgSQL GAC" Installation manually under the options menu on the first screen.
Here is another post where someone did the same:
https://community.powerbi.com/t5/Service/Gateway-error-connecting-to-PostgreSQL/m-p/965710#M89808
- Ivan4ever84Frequent Visitor
I got it!!
On the server you will use as Gateway (that reach the Azure PostgreSQL DB source) you need to:- Install and configure an On-Premises Data Gateway;
- Install the certificate of the Resource you can find on the Azure Portal under Setting--> Network;
- Install a PostgreSQL ODBC Driver (here a list: https://www.postgresql.org/ftp/odbc/versions/msi/);
- Open "ODBC Data Source" and create a System DSN with the informations required (SSL Mode=allow) so test the connection;
If the test is OK, the server is able to connect to Azure PostgreSQL by ODBC then go on Power BI Service and create a new connection using the gateway (local) installed at the point 1 and setting as below:
- Data Source Type: ODBC
- Connection String: dsn=<name of the System DSN choosen at point 4>
- Authentication: Anonymus
- Encryption: Organizational
Here is an example in Italian.