-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
After running one night, Loki lost connection. #1173
Comments
I think you might be experiencing this issue #1087, your loki is working fine since it can accept logs at push endpoint. Please check and let me know whether it works. |
Hi sandlis, |
Yes it means Loki is working fine. Please feel free to reach out if you need any help. |
I added promtail and will see the result tomorrow. |
It looks fine now. But log labels disappeared after a while.
while query from postman or push another new log will get response success.
How can I obtain labels for long time? |
Labels queries have also a start and end parameters, if you haven't
received logs in the last 5min it's normal to not received a response for
the last 5min labels, have you tried to increase the period ?
Le lun. 21 oct. 2019 à 03:10, dudu <notifications@github.com> a écrit :
… It looks fine now. But log labels disappeared after a while.
curl "http://127.0.0.1:3100/api/prom/label"
{}
and grafana query failed too.
[image: image]
<https://user-images.githubusercontent.com/519830/67183182-766e3200-f413-11e9-94a5-b6cc04fd4809.png>
while query from postman or push another new log will get response success.
http://127.0.0.1:3100/api/prom/query?direction=BACKWARD&limit=1000®exp=&query=%7Bmoli2%3D%22zhcn%22%7D&start=1571035785254000000&end=1571640585254000000&refId=A
[image: image]
<https://user-images.githubusercontent.com/519830/67183503-30659e00-f414-11e9-8448-656f28b0402c.png>
How can I obtain labels for long time?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1173?email_source=notifications&email_token=AAIBF3LAFXSL2HBO4NUM2CTQPVIWNA5CNFSM4JCD66QKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBZJKBI#issuecomment-544380165>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIBF3KVWJVINNNIJ5XPS2LQPVIWNANCNFSM4JCD66QA>
.
|
May I ask how to query labels from Grafana's explore page? As you can see when I get in explore page, I just got error, even I had chosen a long term custom time range. |
Are you sending log with the docker driver ? If so can you check daemon logs to verify there isn’t any error ? |
No, I'm sending logs with http post. |
I have the same error. Checking http requests made by grafana I found that it tries to get labels requesting to Can anyone confirm if it's a bug? |
@Mortega5 Thanks for that! For me, even requesting an old timestamp (via firefox devtools) still return an empty json. But... Removing the last zeroes gives me a response with the tags in the first attempt. (take few seconds to return) |
You should have a start and end, the start should be now unix nano minus the time range (1h by default), if this is not the case this is a bug. What version of Grafana are you using ? |
I'm using Grafana v6.4.3 (3a2bfb7) |
You confirm that with this version you get only the |
Actually it makes two request: using only the But I have upgraded loki to last version (loki 1.0.0) and loki response is By the way, changing the time range doesn't refresh the labels, you need to refresh the page. |
@davkal ^^ |
This issue has been automatically marked as stale because it has not had any activity in the past 30 days. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
Describe the bug
I start two docker containers in remote server, Grafana and Loki. It's works well yesterday, After running 20 hours, I found Loki lost connection. Now I cann't set datasource in grafana and get
404 page not found
response fromloki/api/v1/label
I use Loki collecting logs without Promtail, only by pushing api
api/prom/push
.loki-local-config.yaml
andgrafana.ini
are all default settings.To Reproduce
Steps to reproduce the behavior:
http://loki:3100
Bad Gateway. 502
, query with curlhttp://212.64.58.168:3100/loki/api/v1/label
got error404 page not found
. But push apiapi/prom/push
successed.Expected behavior
loki query logs success.
Environment:
Screenshots, Promtail config, or terminal output
The text was updated successfully, but these errors were encountered: