Requirement:
We installed and started Prometheus, however we can't get node-exporter metrics. via /targets , we find the error " ... no route to host "Solution:
The error means Prometheus can't reach http endpoint http://<ip address>:9100/metricsFirst test localhost if it is working on the node
Login Node:
#wget -O- localhost:9100/metrics
If you get output, it means endpoint is working fine. Otherwise check prometheus pod and logs
Then test from the other node
Login other Node:
#wget -O- <ip address>:9100/metrics
If you can't get output, means there are some network or firewall issues
* check the your cloud provider and network security settings, make sure port 9100 is open
* check Node linux firewall service settings. In EL7, default port 9100 is not open
#firewall-cmd --add-port=9100/tcp --permanent
# systemctl restart firewalld
Great, Thanks
ReplyDeleteThanks alot. It worked for me.
ReplyDeleteThanks!
ReplyDeleteThis was the solution for us
Hello, I have written my own exporter, I am getting results with both above commands. But still on prometheus target section, getting same error connect: "no route to host".
ReplyDeleteThank you, its solved for me in my case.
ReplyDelete