Closed
Description
Hello,
New v0.4.0 release version is support PromQL as I understand. Here proof link - https://grafana.com/blog/2019/10/28/whats-new-in-loki-v0.4.0/
I would like to add Loki as Prometheus datasource in Grafana (6.4.3 version) but can't find what is correct address? I already use Loki datasource (address is http://loki:3100) and it works.
I need to use PromQL to configure alert trigger for some log message regexp.
Thanks.
Activity
vukor commentedon Nov 1, 2019
More details:
Inside grafana/loki:v0.4.0 container:
9095 - is some binary data
3100 - Loki datasource, http://loki:3100/loki return 404
negbie commentedon Nov 1, 2019
Hi,
did you try it with curl like in the examples here? Just to make sure that you can reach the query endpoint.
https://github.com/grafana/loki/blob/master/docs/api.md#examples
slim-bean commentedon Nov 1, 2019
Append
loki
to the end of your URL, like this:http://loki:3100/loki
and be sure to select the Prometheus data source type.vukor commentedon Nov 1, 2019
Thanks guys, http://loki:3100/loki looks working.
lobatt commentedon Nov 16, 2019
I know this issue has been closed, but I am having some issue setting this up.
I am thrilled to learn the support for metrics for Loki.
However, when I configure my Prometheus data source to use http://loki:3100/loki as server URL, with latest docker images.
My grafana UI got stucked "Loading metrics", hence not being able to perform any query.
Am I missing anything?
cyriltovena commentedon Nov 17, 2019
No you’re not missing anything. This box doesn’t yet work (soon) but you can still make queries.
lobatt commentedon Nov 17, 2019
Thanks @cyriltovena .
So for keep an eye on the progress, should I watch releases of Loki or Grafana itself?
cyriltovena commentedon Dec 6, 2019
Grafana, there is already a version supporting this but not tagged I think
guobei2028 commentedon Jan 12, 2021
https://[my-loki-url]/loki in my 2.0 version seems to have no effect. Has anyone encountered the same situation?
I already use Loki datasource (address is http://loki:3100) and it works.
frankyaorenjie commentedon Jan 13, 2021
Yes, this solution doesn't work in new version. Grafana 7.4.0-pre. I found a video from Grafana officials to introduce Alert on your Loki logs with Grafana in Feb/2020. Can I say this feature is supported but somehow, doesn't work right now?
In 7.4.0-pre, Grafana will request two APIs:
The request of
query_exemplar
will get a 404 return, and cancel thenquery_range
is cancelled.We also tested 7.0.4 and everything is working fine. There are no
query_exemplar
when Grafana requests backend data source.The exemplar is used to correlate metrics and tracing, from TNS Observability Demo of Grafana/Loki/Prometheus/Tempo. And I guess it is a quite new feature and Loki didn't support it yet.
saibug commentedon May 9, 2022
Having same issue in production !
My loki version is : 2.4.2
From read instance, this is log output :
read_1 | level=error ts=2022-05-09T12:41:32.850473694Z caller=retry.go:73 org_id=fake msg="error processing request" try=4 err="rpc error: code = Code(500) desc = unsupported response type, got (scalar)" read_1 | level=info ts=2022-05-09T12:41:32.850559168Z caller=metrics.go:92 org_id=fake latency=fast query=1+1 query_type=metric range_type=instant length=0s step=0s duration=0s status=500 limit=100 returned_lines=0 throughput=0B total_bytes=0B
Thank you
KVInventoR commentedon May 12, 2022
Hey
same for me, I also got an issue:
grafana 7.0.0