Hi All,
I am using following blackbox configuration. I am trying to reach marathon ping endpoint ( https://ip/ marathon/ping). I give that to Prometheus to scrape blackbox exporter.
modules:
http_2xx:
prober: http
timeout: 5s
http:
preferred_ip_protocol: ip4
valid_status_codes: []
method: GET
# The bearer token for the targets.
bearer_token: <Token>
#bearer_token_file: /Users/kkapoor/go/src/github.com/prometheus/blackbox_exporter/token.txt
Here are the logs from the blackbox probe. I am getting 401 status code. I can do curl at the same time which works fine.
Blackbox exporter.
Logs for the probe:
ts=2018-05-22T18:07:05.028046578Z caller=main.go:118 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Beginning probe" probe=http timeout_seconds=4.5
ts=2018-05-22T18:07:05.028336363Z caller=utils.go:42 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Resolving target address" preferred_ip_protocol=ip4
ts=2018-05-22T18:07:05.03429647Z caller=utils.go:65 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Resolved target address" ip=<IP>
ts=2018-05-22T18:07:05.034387871Z caller=http.go:305 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Making HTTP request" url=<URL>
ts=2018-05-22T18:07:05.055821557Z caller=http.go:326 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Received HTTP response" status_code=401
ts=2018-05-22T18:07:05.055869898Z caller=http.go:341 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Invalid HTTP response status code, wanted 2xx" status_code=401
ts=2018-05-22T18:07:05.055908172Z caller=http.go:380 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=info msg="Response timings for roundtrip" roundtrip=0 start=2018-05-22T14:07:05.034566766-04:00 dnsDone=2018-05-22T14:07:05.034566766-04:00 connectDone=2018-05-22T14:07:05.03844036-04:00 gotConn=2018-05-22T14:07:05.052123031-04:00 responseStart=2018-05-22T14:07:05.055750086-04:00 end=2018-05-22T14:07:05.055777178-04:00
ts=2018-05-22T18:07:05.056034467Z caller=main.go:131 module=http_2xx target=https://ui.dcos.dev.bed.athenahealth.com/marathon/ping level=error msg="Probe failed" duration_seconds=0.02782808
Curl output.
curl -X GET -H "Authorization: token=$(dcos config show core.dcos_acs_token)" $(dcos config show core.dcos_url)/marathon/ping
pong
It would be great if someone can help here.
Regards,
Karan Kapoor
pong
It would be great if someone can help here.
Regards,
Karan Kapoor
--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-users+unsubscribe@googlegroups.com.
To post to this group, send email to prometheus-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/D1C67213-5B32-44CB-A3DD-5851480FC74F%40contoso.com.
For more options, visit https://groups.google.com/d/optout.