Query Azure Log Analytics Logs Raise an Error (v10.1)

What happened?

I installed Azure monitor data source and setup an access with the application in Azure.
I gave application a reader access and all as per instructions.
There are 4 Services available to use: Metrics, Logs, Traces and Azure Resource Graph.
The Metrics and Azure Resource Graph are workable, while the Logs and Traces are not.

If I choose the Logs service and the try to select a resource and click “Apply” button, I get this error:
“Unexpected token ‘u’, “unexpected”… is not valid JSON”


When I try to use the predefined Azure Monitor Dashboards, I have errors where the logs are used, while the Dashboards that use Azure Resource Graph are working fine.

Examples of Dashboards and statuses:
Azure\Alerts Consumption - workable
Virtual Machines by Workspace - not workable, sameJSON error when I open any panel with service = Logs

I also want to mention that when I setup Azure Monitor Data source and click “Save and test” I get this:

One or more health checks failed. See details below.

  1. Successfully connected to Azure Monitor endpoint.
  2. Error connecting to Azure Log Analytics endpoint: health check failed: Post “https://api.loganalytics.io/v1/workspaces/xxx-xxx-xxx/query”: Forbidden
  3. Successfully connected to Azure Resource Graph endpoint.

But I do not use the workspace that is specified in a message and not sure how important it its.

What did you expect to happen?

I expect no errors

Did this work before?

no, we just setup Grafana recently

How do we reproduce it?

  1. Install Azure Monitor plugin
  2. Register application in Azure and give a required access as pr documentation
  3. Setup Data source in Grafana with Application (client) ID and Client Secret
    4.Create a dashboard and choose Azure monitor as data source
    5.Choose the Logs service and the try to select a resource and click “Apply” button

Is the bug inside a dashboard panel?

seems like this

Environment (with versions)?

Grafana: 10.1
OS: Ubuntu
Browser: Crome, Edge

Grafana platform?

A downloaded binary


Azure Monitor\

This is a duplication post from GitHub

Hi, the issue was actually fixed with installation of the version 10.2, but maybe not related to the version itself.
When we installed Grafana version 10.2, there was an error “bad gateway” when I tried to open Grafana connections, so when we changed a proxy server to fix this error, the problem with Azure Monitor Log Analytics was fixed. The issue may be related to the proxy server. We have 2 and one of them didn’t have proper access to Azure Log Analytics most likely. Not sure if the change of proxy would be enough to fix this issue as I am not able to test this theory with the old version.