Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upPrometheus reports malformed alert at wrong line number #2014
Comments
This comment has been minimized.
This comment has been minimized.
|
After some time spent commenting sections of my A completely different rule ( My whole
With the first rule commented out, it works fine. With it included Prometheus tells me |
alexmbird
changed the title
Alert Expression Failing with "expected type vector in alert statement, got scalar"
Prometheus reports malformed alert at wrong line number
Sep 21, 2016
This comment has been minimized.
This comment has been minimized.
|
We'll have to look into this, thank you. In the meantime, you could just use |
grobie
added
kind/bug
component/rules
labels
Sep 21, 2016
tattsun
referenced this issue
Sep 23, 2016
Closed
promql: more appropriate line number of error #2030
This comment has been minimized.
This comment has been minimized.
nicklan
commented
Feb 24, 2017
|
Any update on this? It's still occurring with v1.5.2 and we ran into it. It can make debugging an error in a large rule file nearly impossible (had to resort to binary search, commenting halves of the file) Here's a minimal example rule file that will show the problem:
Using this Prometheus will report on startup:
So it's still just reporting the final line of the file. |
Conorbro
referenced this issue
Apr 18, 2017
Closed
Type check rule expr during parsing to fix incorrect error line number #2636
brian-brazil
referenced this issue
Jun 16, 2017
Closed
promtool reports incorrect line numbers #2857
This comment has been minimized.
This comment has been minimized.
GubendiranM
commented
Jun 28, 2017
|
D:\prometheus\new_prom>prometheus.exe help me... I got above error on bellow configurations in prometheus prometheus.yaml global: rule_files:
rules.conf |
This comment has been minimized.
This comment has been minimized.
|
@GubendiranM Please don't add support requests on unrelated bugs. https://groups.google.com/forum/#!aboutgroup/prometheus-users is the best place to ask questions. |
This comment has been minimized.
This comment has been minimized.
GubendiranM
commented
Jun 28, 2017
|
ok @brian-brazil |
brian-brazil
added
the
priority/P2
label
Jul 14, 2017
This comment has been minimized.
This comment has been minimized.
|
This is obsolete, and #3549 improved the new way of doing things. |
brian-brazil
closed this
Dec 8, 2017
This comment has been minimized.
This comment has been minimized.
lock
bot
commented
Mar 23, 2019
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
alexmbird commentedSep 21, 2016
•
edited
Greetings Prometheans!
See update below...
I am trying to setup alerting for my cluster and have run into a troublesome bug. What I want is pretty standard; to alert for filesystems with less than 20% space free.
Based upon examples I've seen elsewhere it seems the correct thing to do is:
My understanding is that the expression
node_filesystem_free{} / node_filesystem_size{} < 0.2should produce an instance vector of all metrics representing a filesystem with under 20% free. I've tried it out in the console:node_filesystem_free{} / node_filesystem_size{}gives a list of all my filesystems with a value between0and1representing free space. So far so good.node_filesystem_free{} / node_filesystem_size{} < 0.2gives an empty list because this is a good day and none of my filesystems are fullHowever, when I try to deploy this rule by reloading my Prometheus config, it logs the error:
I've been banging my head against this one for a few hours now. Doubtless I'm doing something wrong but no amount of googling reveals what it is. Can somebody please point me in the right direction?
In case it's relevant here's my Prometheus build information: