Datadog : Unable to detect the kubelet URL automatically : datadog_checks.base.errors.CheckException
I set up datadog trace client in my kubernetes cluster to monitor my deployed application. It was working fine with the kubernetes version 1.15x but as soon as I upgraded the version to 1.16x, the service itself is not showing in the Datadog Dashboard.
Currently using:
- Kubernetes 1.16.9
- Datadog 0.52.0
When checked for agent status. It is giving following exception :
Instance ID: kubelet:xxxxxxxxxxxxx [ERROR]
Configuration Source: file:/etc/datadog-agent/conf.d/kubelet.d/conf.yaml.default
Total Runs: 12,453
Metric Samples: Last Run: 0, Total: 0
Events: Last Run: 0, Total: 0
Service Checks: Last Run: 0, Total: 0
Average Execution Time : 5ms
Last Execution Date : 2020-06-19 15:18:19.000000 UTC
Last Successful Execution Date : Never
Error: Unable to detect the kubelet URL automatically.
Traceback (most recent call last):
File "/opt/datadog-agent/embedded/lib/python3.8/site-packages/datadog_checks/base/checks/base.py", line 822, in run
self.check(instance)
File "/opt/datadog-agent/embedded/lib/python3.8/site-packages/datadog_checks/kubelet/kubelet.py", line 297, in check
raise CheckException("Unable to detect the kubelet URL automatically.")
datadog_checks.base.errors.CheckException: Unable to detect the kubelet URL automatically.
This looks like a version issue to me. If it is which Datadog version I need to use for monitoring?
Hi @Sanket110297
Thanks for reaching out! This error is usually displayed when the agent cannot connect to the kubelet, which is required to get kubernetes metrics and make auto-discovery work.
This can be caused by a few different issues:
- certificates are needed
- endpoints are blocked
- service account is not used
Our solution team can help you investigate further. Could you open a ticket with them by sending an email to: [email protected] with an explanation of the issue, the way you deploy the agent (daemonset or helm) and provide the involved manifests/ values.yaml?
Thanks,
Simon
Please reach out to support. I'm going to close the issue since it doesn't appear to be Java related.