Workaround to get the status of a service if port changes each time? (Blackbox_Exporter)

29 views
Skip to first unread message

Sean Coh

unread,
Feb 3, 2023, 2:07:51 PM2/3/23
to Prometheus Users
Hi Guys,

I have an issue that I encounter with some of the services that I'm working with on Blackbox_Exporter. The services that I'm trying to scrape changes port each time. For example on www.example.com:1234 will change to www.example.com:5678 each time the service is stop/start. The hostname stays the same.

Is there another exporter that I can use? or might know of an workaround that would work in this case. Since the url change each time, blackbox exporter cannot be used in this instance.

Thanks,

Stuart Clark

unread,
Feb 3, 2023, 5:32:26 PM2/3/23
to Sean Coh, Prometheus Users
How would you know what port to use?

--
Stuart Clark

Sean Coh

unread,
Feb 3, 2023, 6:20:02 PM2/3/23
to Stuart Clark, Prometheus Users
Please disregard this. I was doing more research and blackbox are only used to scrape third party websites and monitor static ones. There was some confusion on why my website were changing ports because grafana was displaying them 1 at a time. I had to change some of my relabel config to get it working properly.

Thanks,
Sean

> On Feb 3, 2023, at 4:32 PM, Stuart Clark <stuart...@jahingo.com> wrote:
Reply all
Reply to author
Forward
0 new messages