Skip to main content

Kubernetes Containers

Plugin: cgroups.plugin Module: /sys/fs/cgroup

Overview

Monitor Containers for performance, resource usage, and health status.

This collector is supported on all platforms.

This collector supports collecting metrics from multiple instances of this integration, including remote instances.

Default Behavior

Auto-Detection

This integration doesn't support auto-detection.

Limits

The default configuration for this integration does not impose any limits on data collection.

Performance Impact

The default configuration for this integration is not expected to impose a significant performance impact on the system.

Metrics

Metrics grouped by scope.

The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels.

Per k8s cgroup

These metrics refer to the Pod container.

Labels:

LabelDescription
k8s_node_nameNode name. The value of pod.spec.nodeName.
k8s_namespaceNamespace name. The value of pod.metadata.namespace.
k8s_controller_kindController kind (ReplicaSet, DaemonSet, StatefulSet, Job, etc.). The value of pod.OwnerReferences.Controller.Kind.
k8s_controller_nameController name.The value of pod.OwnerReferences.Controller.Name.
k8s_pod_namePod name. The value of pod.metadata.name.
k8s_container_nameContainer name. The value of pod.spec.containers.name.
k8s_kindInstance kind: "pod" or "container".
k8s_qos_classQoS class (guaranteed, burstable, besteffort).
k8s_cluster_idCluster ID. The value of kube-system namespace namespace.metadata.uid.

Metrics:

MetricDimensionsUnit
k8s.cgroup.cpu_limitusedpercentage
k8s.cgroup.cpuuser, systempercentage
k8s.cgroup.cpu_per_corea dimension per corepercentage
k8s.cgroup.throttledthrottledpercentage
k8s.cgroup.throttled_durationdurationms
k8s.cgroup.cpu_sharessharesshares
k8s.cgroup.memcache, rss, swap, rss_huge, mapped_fileMiB
k8s.cgroup.writebackdirty, writebackMiB
k8s.cgroup.mem_activityin, outMiB/s
k8s.cgroup.pgfaultspgfault, swapMiB/s
k8s.cgroup.mem_usageram, swapMiB
k8s.cgroup.mem_usage_limitavailable, usedMiB
k8s.cgroup.mem_utilizationutilizationpercentage
k8s.cgroup.mem_failcntfailurescount
k8s.cgroup.ioread, writeKiB/s
k8s.cgroup.serviced_opsread, writeoperations/s
k8s.cgroup.throttle_ioread, writeKiB/s
k8s.cgroup.throttle_serviced_opsread, writeoperations/s
k8s.cgroup.queued_opsread, writeoperations
k8s.cgroup.merged_opsread, writeoperations/s
k8s.cgroup.cpu_some_pressuresome10, some60, some300percentage
k8s.cgroup.cpu_some_pressure_stall_timetimems
k8s.cgroup.cpu_full_pressuresome10, some60, some300percentage
k8s.cgroup.cpu_full_pressure_stall_timetimems
k8s.cgroup.memory_some_pressuresome10, some60, some300percentage
k8s.cgroup.memory_some_pressure_stall_timetimems
k8s.cgroup.memory_full_pressuresome10, some60, some300percentage
k8s.cgroup.memory_full_pressure_stall_timetimems
k8s.cgroup.io_some_pressuresome10, some60, some300percentage
k8s.cgroup.io_some_pressure_stall_timetimems
k8s.cgroup.io_full_pressuresome10, some60, some300percentage
k8s.cgroup.io_full_pressure_stall_timetimems
k8s.cgroup.pids_currentpidspids

Per k8s cgroup network device

These metrics refer to the Pod container network interface.

Labels:

LabelDescription
deviceThe name of the host network interface linked to the container's network interface.
container_deviceContainer network interface name.
interface_typeNetwork interface type. Always "virtual" for the containers.
k8s_node_nameNode name. The value of pod.spec.nodeName.
k8s_namespaceNamespace name. The value of pod.metadata.namespace.
k8s_controller_kindController kind (ReplicaSet, DaemonSet, StatefulSet, Job, etc.). The value of pod.OwnerReferences.Controller.Kind.
k8s_controller_nameController name.The value of pod.OwnerReferences.Controller.Name.
k8s_pod_namePod name. The value of pod.metadata.name.
k8s_container_nameContainer name. The value of pod.spec.containers.name.
k8s_kindInstance kind: "pod" or "container".
k8s_qos_classQoS class (guaranteed, burstable, besteffort).
k8s_cluster_idCluster ID. The value of kube-system namespace namespace.metadata.uid.

Metrics:

MetricDimensionsUnit
k8s.cgroup.net_netreceived, sentkilobits/s
k8s.cgroup.net_packetsreceived, sent, multicastpps
k8s.cgroup.net_errorsinbound, outbounderrors/s
k8s.cgroup.net_dropsinbound, outbounderrors/s
k8s.cgroup.net_fiforeceive, transmiterrors/s
k8s.cgroup.net_compressedreceive, sentpps
k8s.cgroup.net_eventsframes, collisions, carrierevents/s
k8s.cgroup.net_operstateup, down, notpresent, lowerlayerdown, testing, dormant, unknownstate
k8s.cgroup.net_carrierup, downstate
k8s.cgroup.net_mtumtuoctets

Alerts

The following alerts are available:

Alert nameOn metricDescription
k8s_cgroup_10min_cpu_usage k8s.cgroup.cpu_limitaverage cgroup CPU utilization over the last 10 minutes
k8s_cgroup_ram_in_use k8s.cgroup.mem_usagecgroup memory utilization
k8s_cgroup_1m_received_packets_rate k8s.cgroup.net_packetsaverage number of packets received by the network interface ${label:device} over the last minute
k8s_cgroup_10s_received_packets_storm k8s.cgroup.net_packetsratio of average number of received packets for the network interface ${label:device} over the last 10 seconds, compared to the rate over the last minute

Setup

Prerequisites

No action required.

Configuration

File

There is no configuration file.

Options

There are no configuration options.

Examples

There are no configuration examples.


Do you have any feedback for this page? If so, you can open a new issue on our netdata/learn repository.