-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Prometheus metric data job label name conflict #5345
Comments
@chenjpu 👋 - Is the default |
it's prometheus default |
Interesting - I thought prometheus namespaced all of it's default labels? Afaik you can use relabel_configs to rename collected metrics though? (my prometheus knowledge is pretty high level though) https://github.com/prometheus/prometheus/blob/c7d83b2b6a08048e1bfa046f9fd63125ae327e02/config/testdata/conf.good.yml#L56-L60 |
I have set honor_labels parameter ,but also display error log I found that other projects had similar problems(prometheus/influxdb_exporter#23). Besides,the above error is not present on nomad 0.8.7 version :) |
client_golang(0.9.0 / 2018-10-15) mentioned that |
I ran into this as well but just relabeled the |
I did a simple test, after I upgraded the client_go((0.9.0 / 2018-10-15)), the problem was solved. |
We are running Nomad 0.9.1 and still see this issue. Nomad logs are flooded with a similar error. |
I just upgraded to nomad 0.9.1 today from 0.8.4 and found that I am only getting this error in our environment where we are using periodic/batch jobs. In our other environments where we only have service type jobs, we do not encounter this error and resultant issues with prometheus metrics collection. |
I'm also observing this issue when upgrading 0.8.3 -> 0.9.1. Some additional details:
|
An update about this issue - |
Hi, Depending of task type, we inject different label but prometheus lib seems not compatible with this. All metrics with same name should have same labels. As example service task labels are:
And sync task labels are:
For me, 2 solutions are possible,
What do you think ? |
Up! Will we see this fix in the next release? :) |
…nflict in Nomad 0.9.x reported in #5345
…nflict in Nomad 0.9.x reported in hashicorp#5345
Hello, The problem is still in place. When pushing data to prometheus pushgateway, the job label got rewritten. Only renaming "job" to "job_name" helps us. |
Hi @stremovsky. Sorry to hear that. You're on a version of Nomad that's 0.9.5 or later? |
I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues. |
Nomad version
Nomad v0.9.0-beta2
Operating system and Environment details
CentOS Linux release 7.6.1810 (Core)
Issue
Prometheus metric data job label name conflict.
The prometheus server has a default job label
Nomad Server logs (if appropriate)
nomad: 2019-02-17T03:09:15.387+0800 [INFO ] http.prometheus_handler: error gathering metrics: 35 error(s) occurred:
nomad: * collected metric nomad_nomad_job_summary_queued label:<name:"job" value:"security:1.4.1-RC2" > label:<name:"task_group" value:"security" > gauge:<value:1 > has label dimensions inconsistent with previously collected metrics in the same metric family
nomad: * collected metric nomad_nomad_job_summary_queued label:<name:"job" value:"loki" > label:<name:"task_group" value:"loki" > gauge:<value:0 > has label dimensions inconsistent with previously collected metrics in the same metric family
The text was updated successfully, but these errors were encountered: