SkillAgentSearch skills...

Krr

Prometheus-based Kubernetes Resource Recommendations

Install / Use

/learn @robusta-dev/Krr

README

<!-- @format -->

<a name="readme-top"></a>

<!-- [![Contributors][contributors-shield]][contributors-url] [![Forks][forks-shield]][forks-url] [![Stargazers][stars-shield]][stars-url] [![Issues][issues-shield]][issues-url] [![MIT License][license-shield]][license-url] [![LinkedIn][linkedin-shield]][linkedin-url] -->

![Product Name Screen Shot][product-screenshot]

<div align="center"> <h1 align="center">Kubernetes Resource Recommendations Based on Historical Data</h1> <h2 align="center">Get recommendations based on your existing data in Prometheus/Coralogix/Thanos/Mimir and more!</h2> <p align="center"> <a href="#installation"><strong>Installation</strong></a> . <a href="#how-krr-works"><strong>How KRR works</strong></a> . <a href="#free-krr-ui-on-robusta-saas"><strong>Free KRR UI</strong></a> <br /> <a href="#usage">Usage</a> · <a href="https://github.com/robusta-dev/krr/issues">Report Bug</a> · <a href="https://github.com/robusta-dev/krr/issues">Request Feature</a> · <a href="#support">Support</a> <br /> <br /> <a href="https://trendshift.io/repositories/7087" target="_blank"><img src="https://trendshift.io/api/badge/repositories/7087" alt="robusta-dev%2Fkrr | Trendshift" style="width: 250px; height: 55px;" width="250" height="55"/></a> </p> </div> <!-- TABLE OF CONTENTS --> <!-- <details> <summary>Table of Contents</summary> <ol> <li> <a href="#about-the-project">About The Project</a> <ul> <li><a href="#built-with">Built With</a></li> </ul> </li> <li> <a href="#getting-started">Getting Started</a> <ul> <li><a href="#prerequisites">Prerequisites</a></li> <li><a href="#installation">Installation</a></li> </ul> </li> <li><a href="#usage">Usage</a></li> <li><a href="#roadmap">Roadmap</a></li> <li><a href="#contributing">Contributing</a></li> <li><a href="#license">License</a></li> <li><a href="#contact">Contact</a></li> <li><a href="#acknowledgments">Acknowledgments</a></li> </ol> </details> --> <!-- ABOUT THE PROJECT -->

About The Project

Robusta KRR (Kubernetes Resource Recommender) is a CLI tool for optimizing resource allocation in Kubernetes clusters. It gathers pod usage data from Prometheus and recommends requests and limits for CPU and memory. This reduces costs and improves performance.

Auto-Apply Mode

New: Put right-sizing on auto-pilot by applying recommendations automatically. Request beta access.

Data Integrations

Used to send data to KRR

View Instructions for: Prometheus, Thanos, Victoria Metrics, Google Managed Prometheus, Amazon Managed Prometheus, Azure Managed Prometheus, Coralogix,Grafana Cloud and Grafana Mimir

Reporting Integrations

Used to receive information from KRR

View instructions for: Seeing recommendations in a UI, Sending recommendations to Slack, Setting up KRR as a k9s plugin, Azure Blob Storage Export with Teams Notification

Features

  • No Agent Required: Run a CLI tool on your local machine for immediate results. (Or run in-cluster for weekly Slack reports.)
  • Prometheus Integration: Get recommendations based on the data you already have
  • Explainability: Understand how recommendations were calculated with explanation graphs
  • Extensible Strategies: Easily create and use your own strategies for calculating resource recommendations.
  • Free SaaS Platform: See why KRR recommends what it does, by using the free Robusta SaaS platform.
  • Future Support: Upcoming versions will support custom resources (e.g. GPUs) and custom metrics.

How Much Can I Expect to Save with KRR?

According to a recent Sysdig study, on average, Kubernetes clusters have:

  • 69% unused CPU
  • 18% unused memory

By right-sizing your containers with KRR, you can save an average of 69% on cloud costs.

Read more about how KRR works

Difference with Kubernetes VPA

| Feature 🛠️ | Robusta KRR 🚀 | Kubernetes VPA 🌐 | | --------------------------- | ---------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------- | | Resource Recommendations 💡 | ✅ CPU/Memory requests and limits | ✅ CPU/Memory requests and limits | | Installation Location 🌍 | ✅ Not required to be installed inside the cluster, can be used on your own device, connected to a cluster | ❌ Must be installed inside the cluster | | Workload Configuration 🔧 | ✅ No need to configure a VPA object for each workload | ❌ Requires VPA object configuration for each workload | | Immediate Results ⚡ | ✅ Gets results immediately (given Prometheus is running) | ❌ Requires time to gather data and provide recommendations | | Reporting 📊 | ✅ Json, CSV, Markdown, Web UI, and more! | ❌ Not supported | | Extensibility 🔧 | ✅ Add your own strategies with few lines of Python | :warning: Limited extensibility | | Explainability 📖 | ✅ See graphs explaining the recommendations | ❌ Not supported | | Custom Metrics 📏 | 🔄 Support in future versions | ❌ Not supported | | Custom Resources 🎛️ | 🔄 Support in future versions (e.g., GPU) | ❌ Not supported | | Autoscaling 🔀 | 🔄 Support in future versions | ✅ Automatic application of recommendations | | Default History 🕒 | 14 days | 8 days | | Supports HPA 🔥 | ✅ Enable using --allow-hpa flag | ❌ Not supported |

<!-- GETTING STARTED -->

Installation

Requirements

KRR requires Prometheus 2.26+, kube-state-metrics & cAdvisor.

<details> <summary>Which metrics does KRR need?</summary> No setup is required if you use kube-prometheus-stack or <a href="https://docs.robusta.dev/master/configuration/alertmanager-integration/embedded-prometheus.html">Robusta's Embedded Prometheus</a>.

If you have a different setup, make sure the following metrics exist:

  • container_cpu_usage_seconds_total
  • container_memory_working_set_bytes
  • kube_replicaset_owner
  • kube_pod_owner
  • kube_pod_status_phase

Note: If one of last three metrics is absent KRR will still work, but it will only consider currently-running pods when calculating recommendations. Historic pods that no longer exist in the cluster will not be taken into consideration.

</details>

Installation Methods

<details> <summary>Brew (Mac/Linux)</summary>
  1. Add our tap:
brew tap robusta-dev/homebrew-krr
  1. Install KRR:
brew install krr
  1. Check that installation was successful:
krr --help
  1. Run KRR (first launch might take a little longer):
krr simple
</details> <details> <summary>Windows</summary>

You can install using brew (see above) on WSL2, or install from source (see below).

</details> <details> <summary>Docker image, binaries, and airgapped installation (offline environments)</summary>

You can download pre-built binaries from <a href="https://github.com/robusta-dev/krr/releases">Releases</a> or use the prebuilt Docker container. For example, the container for version 1.8.3 is:

us-central1-docker.pkg.dev/genuine-flight-317411/devel/krr:v1.8.3

We do not recommend installing KRR from source in airgapped environments due to the headache of installing Python dependencies. Use one of the above methods instead and contact us (via Slack, GitHub issues, or email) if you need assistance.

</details> <details> <summary>In-Cluster</summary>

Apart from running KRR as a CLI tool you can also run KRR inside your cluster. We suggest installing KRR via th

Related Skills

View on GitHub
GitHub Stars4.5k
CategoryDevelopment
Updated11h ago
Forks263

Languages

Python

Security Score

100/100

Audited on Mar 26, 2026

No findings