on 10 May 2024 08:00 AM - edited on 22 May 2024 12:20 PM by Michal_Gebacki
Disclaimer: Some changes will be introduced with SaaS 1.294 and 1.296, you can read more about it in Introducing Intergrated Persistent Volume Claim Monitoring for Kubernetes.
However, the steps mentioned for analysis are still valid.
Please note that there are a few prerequisites that you must meet in order for your PVC data to be reflected in Dynatrace.
Please note that there is a limitation:
This feature is only available if your Kubernetes cluster is connected to a local Kubernetes API endpoint.If, however, you still do not see any data on the dashboard, please check the following points:
Please execute the following command on the Kubernetes cluster and substitute the {NODE-NAME} with your node name, which corresponds to the PVC.
kubectl get --raw /api/v1/nodes/{NODE-NAME}/proxy/metrics | grep kubelet_volume_stats_
This query will retrieve all volume stats metrics exposed by the kubelet. To locate a specific pod, use the pod, namespace, and persistentvolumeclaim labels. If the CSI driver mounting a volume does not expose volume statistics, this is indicated by missing PVC metrics for a pod claiming that volume.
For further information, please consult the documentation of a specific CSI driver to see if it exposes volume statistics.
If, however, you have results based on the previous kubectl command, it may be a connection issue with the metrics endpoint.
To check the status of connectivity, please execute the following query in Dynatrace Data Explorer. Please ensure that you replace the {K8S_CLUSTER_NAME} with your actual Kubernetes cluster name.
dsfm:active_gate.kubernetes.api.query_count:filter(and(or(in("dt.entity.kubernetes_cluster",entitySelector("type(kubernetes_cluster),entityName.equals(~"{K8S_CLUSTER_NAME}~")"))),or(eq(path,"/metrics")))):splitBy(status_code,status_reason):sum:sort(value(sum,descending)):limit(20)
The connection status can also be checked from the logs of the ActiveGate container. To do so, open the Properties and tags of your Kubernetes cluster connection, and click on the hyperlink of the ActiveGate ID. This will redirect you to the deployment status, filtering directly for the ActiveGate ID in question.
Please run the ActiveGate diagnostics, save the results locally, and unzip them. In the log folder, open the dynatracegateway.0.0.log file and look for log lines similar to the following:
The IP address displayed indicates the location where the ActiveGate pod attempts to connect. It is recommended that you consult with your Kubernetes administrator to verify the connectivity.
If you do not see a timeout message in Data Explorer or in the ActiveGate logs, please submit a support ticket. Please include a detailed description of the steps you have taken to check the issue, as this will help us to investigate it more efficiently.