Skip to content
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 failed sending data to openTSDB #2075

Closed
reAsOn2010 opened this Issue Oct 11, 2016 · 7 comments

Comments

Projects
None yet
3 participants
@reAsOn2010
Copy link

reAsOn2010 commented Oct 11, 2016

I'm using prometheus with remote storage of openTSDB, but prometheus failed to send metrics.

prometheus version 1.2.0
openTSDB version 2.2.0

prometheus log:

time="2016-10-11T07:43:46Z" level=warning msg="error sending 100 samples to remote storage: Post http://opentsdb-1.default.svc:4242/api/put: read tcp 192.168.75.6:32806->192.168.71.7:4242: i/o timeout" source="queue_manager.go:246" 
time="2016-10-11T07:43:46Z" level=warning msg="error sending 100 samples to remote storage: Post http://opentsdb-1.default.svc:4242/api/put: read tcp 192.168.75.6:32807->192.168.71.7:4242: i/o timeout" source="queue_manager.go:246" 
time="2016-10-11T07:43:46Z" level=warning msg="error sending 100 samples to remote storage: Post http://opentsdb-1.default.svc:4242/api/put: read tcp 192.168.75.6:32808->192.168.71.7:4242: i/o timeout" source="queue_manager.go:246" 
time="2016-10-11T07:43:46Z" level=warning msg="error sending 100 samples to remote storage: Post http://opentsdb-1.default.svc:4242/api/put: read tcp 192.168.75.6:32809->192.168.71.7:4242: i/o timeout" source="queue_manager.go:246"
time="2016-10-11T07:43:48Z" level=warning msg="cannot send value NaN to OpenTSDB, skipping sample &model.Sample{Metric:model.Metric{\"operation_type\":\"runContainerInPod\", \"quantile\":\"0.5\", \"__name__\":\"kubelet_container_manager_latency_microseconds\", \"job\":\"kubernetes-nodes\", \"beta_kubernetes_io_os\":\"linux\", \"kubernetes_io_hostname\":\"kube-node-1\", \"beta_kubernetes_io_arch\":\"amd64\", \"instance\":\"kube-node-1\"}, Value:NaN, Timestamp:1476171826102}" source="client.go:79"

openTSDB log:

2016-10-11 07:43:46,756 INFO  [OpenTSDB I/O Worker #3] ConnectionManager: [id: 0x8512e244, /192.168.75.6:32803 :> /192.168.71.7:4242] CLOSED
2016-10-11 07:43:46,915 INFO  [OpenTSDB I/O Boss #1] ConnectionManager: [id: 0x17ba8b25, /192.168.75.6:32806 => /192.168.71.7:4242] OPEN
2016-10-11 07:43:46,915 INFO  [OpenTSDB I/O Boss #1] ConnectionManager: [id: 0x2c9fbab5, /192.168.75.6:32807 => /192.168.71.7:4242] OPEN
2016-10-11 07:43:46,915 INFO  [OpenTSDB I/O Worker #5] ConnectionManager: [id: 0x17ba8b25, /192.168.75.6:32806 => /192.168.71.7:4242] BOUND: /192.168.71.7:4242
2016-10-11 07:43:46,916 INFO  [OpenTSDB I/O Worker #5] ConnectionManager: [id: 0x17ba8b25, /192.168.75.6:32806 => /192.168.71.7:4242] CONNECTED: /192.168.75.6:32806
2016-10-11 07:43:46,917 INFO  [OpenTSDB I/O Worker #7] ConnectionManager: [id: 0x2c9fbab5, /192.168.75.6:32807 => /192.168.71.7:4242] BOUND: /192.168.71.7:4242
2016-10-11 07:43:46,920 INFO  [OpenTSDB I/O Worker #5] ConnectionManager: [id: 0x17ba8b25, /192.168.75.6:32806 :> /192.168.71.7:4242] DISCONNECTED
2016-10-11 07:43:46,929 INFO  [OpenTSDB I/O Worker #7] ConnectionManager: [id: 0x2c9fbab5, /192.168.75.6:32807 => /192.168.71.7:4242] CONNECTED: /192.168.75.6:32807
2016-10-11 07:43:46,932 INFO  [OpenTSDB I/O Worker #7] ConnectionManager: [id: 0x2c9fbab5, /192.168.75.6:32807 :> /192.168.71.7:4242] DISCONNECTED
2016-10-11 07:43:46,933 INFO  [OpenTSDB I/O Worker #7] ConnectionManager: [id: 0x2c9fbab5, /192.168.75.6:32807 :> /192.168.71.7:4242] UNBOUND
2016-10-11 07:43:46,935 INFO  [OpenTSDB I/O Worker #7] ConnectionManager: [id: 0x2c9fbab5, /192.168.75.6:32807 :> /192.168.71.7:4242] CLOSED
2016-10-11 07:43:46,936 INFO  [OpenTSDB I/O Worker #5] ConnectionManager: [id: 0x17ba8b25, /192.168.75.6:32806 :> /192.168.71.7:4242] UNBOUND
2016-10-11 07:43:46,937 INFO  [OpenTSDB I/O Worker #5] ConnectionManager: [id: 0x17ba8b25, /192.168.75.6:32806 :> /192.168.71.7:4242] CLOSED
2016-10-11 07:43:46,956 INFO  [OpenTSDB I/O Boss #1] ConnectionManager: [id: 0x4175e3a6, /192.168.75.6:32808 => /192.168.71.7:4242] OPEN
2016-10-11 07:43:46,962 INFO  [OpenTSDB I/O Boss #1] ConnectionManager: [id: 0xe9fc750b, /192.168.75.6:32809 => /192.168.71.7:4242] OPEN
2016-10-11 07:43:46,964 INFO  [OpenTSDB I/O Worker #11] ConnectionManager: [id: 0xe9fc750b, /192.168.75.6:32809 => /192.168.71.7:4242] BOUND: /192.168.71.7:4242
2016-10-11 07:43:46,964 INFO  [OpenTSDB I/O Worker #11] ConnectionManager: [id: 0xe9fc750b, /192.168.75.6:32809 => /192.168.71.7:4242] CONNECTED: /192.168.75.6:32809
2016-10-11 07:43:46,962 INFO  [OpenTSDB I/O Worker #6] ConnectionManager: [id: 0x4175e3a6, /192.168.75.6:32808 => /192.168.71.7:4242] BOUND: /192.168.71.7:4242
2016-10-11 07:43:46,968 INFO  [OpenTSDB I/O Worker #6] ConnectionManager: [id: 0x4175e3a6, /192.168.75.6:32808 => /192.168.71.7:4242] CONNECTED: /192.168.75.6:32808
2016-10-11 07:43:46,973 INFO  [OpenTSDB I/O Worker #11] ConnectionManager: [id: 0xe9fc750b, /192.168.75.6:32809 :> /192.168.71.7:4242] DISCONNECTED
2016-10-11 07:43:46,974 INFO  [OpenTSDB I/O Worker #11] ConnectionManager: [id: 0xe9fc750b, /192.168.75.6:32809 :> /192.168.71.7:4242] UNBOUND
2016-10-11 07:43:46,980 INFO  [OpenTSDB I/O Worker #11] ConnectionManager: [id: 0xe9fc750b, /192.168.75.6:32809 :> /192.168.71.7:4242] CLOSED
2016-10-11 07:43:46,980 INFO  [OpenTSDB I/O Worker #6] ConnectionManager: [id: 0x4175e3a6, /192.168.75.6:32808 :> /192.168.71.7:4242] DISCONNECTED
2016-10-11 07:43:46,998 INFO  [OpenTSDB I/O Worker #6] ConnectionManager: [id: 0x4175e3a6, /192.168.75.6:32808 :> /192.168.71.7:4242] UNBOUND
2016-10-11 07:43:46,998 INFO  [OpenTSDB I/O Worker #6] ConnectionManager: [id: 0x4175e3a6, /192.168.75.6:32808 :> /192.168.71.7:4242] CLOSED
2016-10-11 07:43:49,000 INFO  [OpenTSDB I/O Boss #1] ConnectionManager: [id: 0xd43b2356, /192.168.75.6:32812 => /192.168.71.7:4242] OPEN
2016-10-11 07:43:49,002 INFO  [OpenTSDB I/O Boss #1] ConnectionManager: [id: 0xa163f990, /192.168.75.6:32813 => /192.168.71.7:4242] OPEN

Comparing the date time of the log, the two parts of log is corresponding. openTSDB said the connection was closed shortly after connection open, but prometheus said it was timed out...

They all running in k8s. But my partner @harryge00 reproduced this problem locally on his PC.

@harryge00

This comment has been minimized.

Copy link

harryge00 commented Oct 11, 2016

prometheus version 1.1.0 can work locally.

@brian-brazil

This comment has been minimized.

Copy link
Member

brian-brazil commented Oct 26, 2016

This smells like a network issue on your end. Does sending data by hand work?

@reAsOn2010

This comment has been minimized.

Copy link
Author

reAsOn2010 commented Oct 26, 2016

No network issue, we just downgraded prometheus's version to 1.1.x, everything went well~

But I noticed that in 1.2.0 the command line config storage.remote.timeout was removed, and the log said that prometheus closed the connection self throwing timeout exceptions. Is the timeout configuration not properly applied?

@brian-brazil

This comment has been minimized.

Copy link
Member

brian-brazil commented Oct 26, 2016

That would be a regression from #1957 alright. Not that this code is going to kicked out to separate binaries soon anyway.

@reAsOn2010

This comment has been minimized.

Copy link
Author

reAsOn2010 commented Oct 26, 2016

@brian-brazil
so the command line config seems to be deprecated in the future, where could I find some examples configuring remote storage using yaml config file? I found no docs about this...

@brian-brazil

This comment has been minimized.

Copy link
Member

brian-brazil commented Oct 26, 2016

https://www.robustperception.io/using-the-remote-write-path/

The existing 3 remote storage integrations will have their code moved out somewhere so you can use them with this.

brian-brazil added a commit that referenced this issue Oct 26, 2016

brian-brazil added a commit that referenced this issue Oct 26, 2016

@brian-brazil brian-brazil added kind/bug and removed kind/bug labels Jul 14, 2017

@lock

This comment has been minimized.

Copy link

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.

@lock lock bot locked and limited conversation to collaborators Mar 23, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.