Wednesday, February 13, 2019

Azure Log Analytics and Grafana - Data Source creation failed

I’ve been playing around with connecting Grafana to Azure Monitor and Azure Log Analytics for dashboarding purposes, and ran into an issue with the creation of the data source. It succeeded on creation for Azure Monitor, but returned an error relating to authentication for the Log Analytics portion that looks like this:

1. Successfully queried the Azure Monitor service. 2. Azure Log Analytics: Forbidden: InsufficientAccessError. The provided credentials have insufficient access to perform the requested operation

I made sure I created the service principal and gave it access to the Log Analytics workspace, and even tried elevated permissions, but none of this worked.

I had created a Grafana instance from the Azure marketplace, which created a virtual machine with Ubuntu installed, and Grafana on top of that. It installed Grafana version 5.1.0, and I found a comment somewhere in my searches that an upgrade of Grafana to the latest version resolves this issue.

Following the upgrade instructions did not work, as apt-get returned version is current.

Instead, I had to follow the installation instructions, which meant downloading the binaries for the latest version, and then installing that. Once the upgrade completed and I restarted the services, the data source created without error, and I was able to create dashboards using standard Kusto queries.

No comments:

Related Posts with Thumbnails