Closed jiang-wei closed 6 years ago
BTW I'm using
<id>prometheus</id>
<dependencies>
<dependency>
<groupId>io.prometheus</groupId>
<artifactId>simpleclient</artifactId>
<version>${prometheus-simpleclient.version}</version>
</dependency>
<dependency>
<groupId>io.prometheus</groupId>
<artifactId>simpleclient_servlet</artifactId>
<version>${prometheus-simpleclient.version}</version>
</dependency>
<dependency>
<groupId>io.prometheus</groupId>
<artifactId>simpleclient_dropwizard</artifactId>
<version>${prometheus-simpleclient.version}</version>
</dependency>
</dependencies>
prometheus-simpleclient.version = 0.4.0 to expose metrics
more info:
it seems some metrics may cause the crash.
promtool check metrics
jvm_buffers_direct_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_buffers_mapped_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_garbage_PS_MarkSweep_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_garbage_PS_Scavenge_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_blocked_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_daemon_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_deadlock_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_new_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_runnable_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_terminated_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_timed_waiting_count non-histogram and non-summary metrics should not have "_count" suffix
jvm_threads_waiting_count non-histogram and non-summary metrics should not have "_count" suffix
I just released version 0.4.3 with PR #8 Thanks for the help!
What did you do? Run prometheus in GKE 1.10 What did you expect to see?
What did you see instead? Under which circumstances? Sometimes it works just ok. But after a while it just crashes and GKE will pull it up.
The same thing happens to release-0.4.2 as well.
I doubt there are some dirty metric pages prometheus does not parse very well.
Here is the log
Environment GKE 1.10.2 image: gcr.io/stackdriver-prometheus/stackdriver-prometheus:release-0.4.1
System information:
insert output of
uname -srm
herePrometheus version:
0.4.1
Alertmanager version:
Prometheus configuration file:
insert configuration here (if relevant to the issue)
level=debug ts=2018-05-24T16:04:43.708021696Z caller=client.go:148 component=remote msg="sending request to Stackdriver" panic: runtime error: invalid memory address or nil pointer dereference [signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x15f8007]
goroutine 214 [running]: github.com/Stackdriver/stackdriver-prometheus/retrieval.subtractResetValue(0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc1, 0x0, 0xc4213cff80) /Users/bmoyles/go/src/github.com/Stackdriver/stackdriver-prometheus/retrieval/scrape.go:965 +0x177 github.com/Stackdriver/stackdriver-prometheus/retrieval.(pointExtractor).UpdateValue(0xc420b571a0, 0xc4209bc550, 0xc4213cff80, 0xc420d3a600, 0xc42142a378, 0x1, 0x1) /Users/bmoyles/go/src/github.com/Stackdriver/stackdriver-prometheus/retrieval/scrape.go:893 +0x5a9 github.com/Stackdriver/stackdriver-prometheus/retrieval.(scrapeLoop).append(0xc420bd59a0, 0xc421512000, 0x6a4c, 0x9ab9, 0xbeb9d687525f322a, 0x1506577f6d, 0x2a57400, 0x0, 0x0, 0x0, ...) /Users/bmoyles/go/src/github.com/Stackdriver/stackdriver-prometheus/retrieval/scrape.go:675 +0x56d github.com/Stackdriver/stackdriver-prometheus/retrieval.(scrapeLoop).run(0xc420bd59a0, 0xdf8475800, 0x2540be400, 0x0) /Users/bmoyles/go/src/github.com/Stackdriver/stackdriver-prometheus/retrieval/scrape.go:599 +0x6a3 created by github.com/Stackdriver/stackdriver-prometheus/retrieval.(scrapePool).sync /Users/bmoyles/go/src/github.com/Stackdriver/stackdriver-prometheus/retrieval/scrape.go:309 +0x2fc