AKS 1.19.X missing metrics & alerts in Azure Monitor for containers
What happened: Starting AKS version 1.19.X due to k8s upstream issue, Azure Monitor for containers customers will not see all the metrics under 'insights.container/nodes' metrics namespace & the recommended alerts using these metrics will be broken.
This is due to the k8s upstream issue of missing cAdvisor metrics Anything else we need to know?: This issue will be fixed once the k8s upstream issue is fixed & backported to AKS.
Please reach out to akscoin@microsoft for any question. Environment: AKS version 1.19.X.
Hi saaror, AKS bot here :wave: Thank you for posting on the AKS Repo, I'll do my best to get a kind human from the AKS team to assist you.
I might be just a bot, but I'm told my suggestions are normally quite good, as such:
- If this case is urgent, please open a Support Request so that our 24/7 support team may help you faster.
- Please abide by the AKS repo Guidelines and Code of Conduct.
- If you're having an issue, could it be described on the AKS Troubleshooting guides or AKS Diagnostics?
- Make sure your subscribed to the AKS Release Notes to keep up to date with all that's new on AKS.
- Make sure there isn't a duplicate of this issue already reported. If there is, feel free to close this one and '+1' the existing issue.
- If you have a question, do take a look at our AKS FAQ. We place the most common ones there!
@vishiy, @saaror would you be able to assist?
Issue Details
What happened: Starting AKS version 1.19.X due to k8s upstream issue, Azure Monitor for containers customers will not see all the metrics under 'insights.container/nodes' metrics namespace & the recommended alerts using these metrics will be broken.
This is due to the k8s upstream issue of missing cAdvisor metrics Anything else we need to know?: This issue will be fixed once the k8s upstream issue is fixed & backported to AKS.
Please reach out to akscoin@microsoft for any question. Environment: AKS version 1.19.X.
| Author: | saaror |
|---|---|
| Assignees: | - |
| Labels: |
|
| Milestone: | - |
Impact: High, breaking existing customer alerts.
Caused by a kubernetes bug that is tracked by - https://github.com/kubernetes/kubernetes/issues/95204
This bug is now fixed upstream, is there any ETA on when it will be released on AKS?
It is possible to handle this with some urgency now? Node metrics are critical part of AKS monitoring... Thanks!
Thanks folks for the patience. The fix is completed on AKS side & should be rolling out AKS next week release in 1.19.7 version.
@saaror Thanks! But when I check available upgrades for eastus2 there is only 1.19.6 version. Does this version contain the fix as well?
EDIT: According to Kubernetes change log - this is fixed in version 1.19.7
1.19.6 doesn't contain a fix for missing cAdvisor machine metrics. Please release AKS 1.19.7 version ASAP.
Thank you!
I was receiving the following error messages when attempting to deploy the 2 metrics memoryWorkingSetPercentage and cpuUsagePercentage. I tried running the deployment after upgrading to AKS 1.19.7 in NorthEurope but continue to get this error. Am I missing something else?
"Message": "The following metric name(s) were not found: memoryWorkingSetPercentage. Please note that for custom metrics, the relevant metric namespace must be specified. Activity ID: b88057d0-1658-4060-bb36-b1ed8a4e2b2b."
"Message": "The following metric name(s) were not found: cpuUsagePercentage. Please note that for custom metrics, the relevant metric namespace must be specified. Activity ID: 74a35ec4-e3d9-446e-9730-41c0992ea43e."
@adhodgson1 Have you activated the Monitoring Metrics Publisher role for your cluster?
@saaror Update: Tried it myself with no luck.. Other metrics are showing up, but the ones I would like to see (memoryWorkingSetPercentage, cpuUsagePercentage in Insights.container/nodes) are not present
@aristosvo I am creating the relevant RBAC entry as part of the deployment as the account that runs the ARM template doesn't have the capability to update RBAC. Here is the Ansible code:
- name: Ensure AKS Monitoring identity has 'Monitoring Metrics Publisher' rights to the AKS resource
azure_rm_roleassignment:
scope: "{{ aks_resource_id }}"
assignee_object_id: "{{ oms_managed_identity_object_id }}"
role_definition_id: "/subscriptions/{{ azure_subscription_id }}/providers/Microsoft.Authorization/roleDefinitions/3913510d-42f4-4e42-8a64-420c390055eb"
I can share the ARM template if required.
@adhodgson1 the setup is the same as I have, it seems still broken in 1.19.7 😥
@adhodgson1 the setup is the same as I have, it seems still broken in 1.19.7 😥
Same here, we just rolled a new 1.19.7 cluster and cannot see all metrics under insights.container/nodes.
The fix for the monitoring addon for this issue is in the works. Once the addon is patched, >=1.19.7 & >=1.20.2 clusters will start to collect these metrics.
@vishiy Thanks for letting us know! Is this also fixing https://github.com/Azure/AKS/issues/2078#issuecomment-772125200?
Is there a place where RCAs and mitigation of known issues like these are published, to inform my clients and manager about these kind of things?
@aristosvo - Can you please share more on #2078 ?
Issue seems resolved in my clusters, thanks!!
I can confirm this is now resolved for us as well - cluster version 1.19.7
Closing issue, the fix has been rolled out.