GridProtectionAlliance / osisoftpi-grafana

Grafana Data Source Plugin for the OSIsoft PI System
https://grafana.com/plugins/gridprotectionalliance-osisoftpi-datasource
Apache License 2.0
58 stars 30 forks source link

Problems creating new data source - Bad Gateway #81

Closed gschwepp closed 2 years ago

gschwepp commented 2 years ago

Hello,

I have currently the problem that I cannot add an OSIsoft-PI data source to Grafana.

My Dev Environment:

Grafana and the piwebapi are running on the same computer. For this test I configured the piwebapi to also allow anonymous login. PI-AF, PI-DA and webapi are working properly, as I can query the information with my webbrowser.

The problem:

When I add my webapi URL to the accodring field and hit "Save & Test" I get the notification Bad Gateway. None of the settings seem to solve this problem.

Antoher Problem:

As soon as I remove /piwebapi from the URL the notifcation changes to Data source is working. But it is not. The notification stays the same regardless what I change. Even if I add /piwebapi again back to the URL.

Both behaviours seem wrong to me. Do you require more information from me to resolve this issue?

Thanks a lot.

coderReview commented 2 years ago

@gschwepp I don't think we ever tried anonymous login. Can you try with Basic authentication and see if that works?

gschwepp commented 2 years ago

Hi thank you for you quick response,

this is interesting the another problem does not occur anymore. Anyhow the first problem still happens as described. I configured the datasource as following:

grafik

The credentials and the url for the webapi are correct. Any suggestions where to look? After a quick google search this seems to be a known issue, however I didn't find a definite answer to this. Do you have any suggestions where to look? Both, the grafana and the piwebapi logs are not too informative at this point.

Thanks.

coderReview commented 2 years ago

You can enable debug in the grafana.ini file

coderReview commented 2 years ago

Also, please define the PI Server, AF server and AF Default Database

gschwepp commented 2 years ago

Thank you for your help. I will look into it during the week.

coderReview commented 2 years ago

I will close this. No more activity.