Home Explore Blog CI



kubernetes

1st chunk of `content/en/blog/_posts/2015-05-00-Resource-Usage-Monitoring-Kubernetes.md`
18293b0626dcb090923b229d26f694b7a1ebbad2265a32c700000001000008d2
---
title:  Resource Usage Monitoring in Kubernetes
date: 2015-05-12
slug: resource-usage-monitoring-kubernetes
url: /blog/2015/05/Resource-Usage-Monitoring-Kubernetes
author: >
   Vishnu Kannan (Google),
   Victor Marmol (Google)
---

Understanding how an application behaves when deployed is crucial to scaling the application and providing a reliable service. In a Kubernetes cluster, application performance can be examined at many different levels: containers, [pods](/docs/user-guide/pods), [services](/docs/user-guide/services), and whole clusters. As part of Kubernetes we want to provide users with detailed resource usage information about their running applications at all these levels. This will give users deep insights into how their applications are performing and where possible application bottlenecks may be found. In comes [Heapster](https://github.com/kubernetes/heapster), a project meant to provide a base monitoring platform on Kubernetes.  


**Overview**  


Heapster is a cluster-wide aggregator of monitoring and event data. It currently supports Kubernetes natively and works on all Kubernetes setups. Heapster runs as a pod in the cluster, similar to how any Kubernetes application would run. The Heapster pod discovers all nodes in the cluster and queries usage information from the nodes’ [Kubelets](https://github.com/kubernetes/kubernetes/blob/master/DESIGN.md#kubelet), the on-machine Kubernetes agent. The Kubelet itself fetches the data from [cAdvisor](https://github.com/google/cadvisor). Heapster groups the information by pod along with the relevant labels. This data is then pushed to a configurable backend for storage and visualization. Currently supported backends include [InfluxDB](http://influxdb.com/) (with [Grafana](http://grafana.org/) for visualization), [Google Cloud Monitoring](https://cloud.google.com/monitoring/) and many others described in more details here. The overall architecture of the service can be seen below:  


[![](https://2.bp.blogspot.com/-6Bu15356Zqk/V4mGINP8eOI/AAAAAAAAAmk/-RwvkJUt4rY2cmjqYFBmRo25FQQPRb27ACEw/s640/monitoring-architecture.png)](https://2.bp.blogspot.com/-6Bu15356Zqk/V4mGINP8eOI/AAAAAAAAAmk/-RwvkJUt4rY2cmjqYFBmRo25FQQPRb27ACEw/s1600/monitoring-architecture.png)

Title: Resource Usage Monitoring in Kubernetes with Heapster
Summary
This blog post introduces Heapster, a cluster-wide aggregator of monitoring and event data for Kubernetes. Heapster collects resource usage information from Kubelets on each node, aggregates it by pod, and pushes it to a configurable backend (like InfluxDB or Google Cloud Monitoring) for storage and visualization. It provides insights into application performance at different levels within a Kubernetes cluster.