Skip to main content
XenonStack

Kubernetes

Enterprise AI

Cloud Native Applications

XenonStack Blog AI Agents for Kubernetes Operations: LLMs in Practice

and | Published

AI Agents for Kubernetes Operations: LLMs in Practice
5:29

Key takeaway

  • How LLMs and AI agents help run Kubernetes: troubleshooting, upgrades, cost and security, the open-source tools, the risks and the guardrails to set.

Large language models help run Kubernetes by turning cluster state, events and logs into plain-language diagnoses and proposed fixes, and AI agents go further by running checks and applying approved changes. The best results so far are in troubleshooting, upgrade preparation, cost reviews and policy checks. The main risk is giving an agent more control of a cluster than its evidence justifies.

This guide explains where LLMs help in Kubernetes managed services, the open-source tools teams use, the guardrails that keep clusters safe, and how a managed service provider should combine people and agents.

What are Kubernetes managed services?

Kubernetes managed services cover the work of running clusters for a business: provisioning, upgrades, security, monitoring, incident response and cost control, delivered by a cloud provider, a partner or both. Our buyer's guide to Kubernetes managed services companies covers how to evaluate providers. This post focuses on how AI changes the operating model.

Where do LLMs help in Kubernetes operations?

TaskWhat the model doesWho decides
TroubleshootingExplains failing pods, events and logs in plain language and suggests likely causesEngineer, or agent within read-only scope
Upgrade preparationFinds deprecated APIs and summarises release notes against your manifestsPlatform team
Configuration reviewFlags missing limits, probes and risky settingsPlatform team, enforced by policy
Cost reviewExplains idle and oversized workloads and proposes right-sizingService owner
Incident responseCorrelates alerts, drafts the timeline and runs approved runbooksOn-call engineer
KnowledgeAnswers questions from runbooks and past incidentsAnyone, with access controls

Which open-source AI tools work with Kubernetes?

  • K8sGPT: scans clusters with built-in analysers and uses a model to explain findings. It was accepted to the CNCF at Sandbox level on 19 December 2023.
  • HolmesGPT: an open-source troubleshooting agent that combines telemetry, model reasoning and runbooks; it became a CNCF Sandbox project in October 2025.
  • kagent: a framework for building agents that operate Kubernetes, also in the CNCF Sandbox.
  • Copilots for kubectl and YAML: assistants that suggest commands and manifests for an engineer to run.

Sandbox status means early-stage projects: test them in non-production clusters and pin versions.

How does an AI agent work safely on a cluster?

Flow diagram of an AI agent in Kubernetes operations: detect, diagnose read-only, propose a change, policy check and human approval, apply through GitOps and verify

  1. Detect: an alert or scheduled scan starts the run.
  2. Diagnose read-only: the agent reads events, logs and metrics with a read-only service account.
  3. Propose: it writes the fix as a pull request or runbook step, never a direct edit.
  4. Check and approve: policy engines validate the change and a named engineer approves anything risky.
  5. Apply and verify: GitOps applies the change, and the agent confirms the service recovered.

Our guides to Kubernetes deployment and GitOps workflows cover the delivery side.

What are the risks of using LLMs to manage Kubernetes?

  • Over-privileged agents: a cluster-admin token turns a wrong suggestion into an outage.
  • Sensitive data: logs and manifests can contain secrets and personal data sent to a model.
  • Confident errors: plausible but wrong diagnoses waste time or cause bad changes.
  • Prompt injection: text in logs or annotations can try to redirect the agent.
  • No audit trail: without records, nobody can show why a change was made.

See agentic AI security and site reliability engineering for the wider controls.

Where does XenonStack fit?

Solution diagram: Kubernetes clusters and telemetry feed AI diagnostics, with ElixirData Context OS and ElixirClaw adding policy, approvals and governed operations agents alongside XenonStack managed services

XenonStack runs Kubernetes managed services with engineers and agents working together. ElixirClaw runs governed operations agents with least-privilege access and approval steps, and ElixirData Context OS holds change policy and records a decision trace for every action, so audits and post-incident reviews have the full story.

To map one operations decision your agents should make, and the context and policy it depends on, book a Context Workshop. See what happens in the workshop.

Frequently asked questions

Can an LLM manage a Kubernetes cluster on its own?

Not safely today for production changes. LLMs are strong at diagnosis and drafting fixes; changes should go through policy checks, GitOps and human approval for anything risky.

What is K8sGPT?

K8sGPT is an open-source tool that scans Kubernetes clusters with analysers and uses a language model to explain problems in plain English. It was accepted to the CNCF as a Sandbox project in December 2023.

How do you keep secrets out of AI tools?

Redact or filter secrets and personal data before anything is sent to a model, use read-only service accounts, prefer models you can host privately, and log what was shared.

Will AI replace Kubernetes engineers?

No. It reduces toil in triage, reviews and documentation, but engineers still own architecture, approvals and accountability for production changes.

How should a managed service provider use AI agents?

Start with read-only diagnosis, measure accuracy against engineers, then allow agents to propose changes through pull requests, with approval gates and a decision record for every action.

Follow XenonStack on LinkedIn: XenonStack on LinkedIn for new guides on agentic AI, data and platform engineering.

Table of Contents

navdeep-singh-gill

Navdeep Singh Gill

Global CEO and Founder of XenonStack

LinkedIn profile

Navdeep Singh Gill is serving as Chief Executive Officer and Product Architect at XenonStack. He holds expertise in building SaaS Platform for Decentralised Big Data management and Governance, AI Marketplace for Operationalising and Scaling. His incredible experience in AI Technologies and Big Data Engineering thrills him to write about different use cases and its approach to solutions.

Get the latest articles in your inbox

Subscribe Now

Interested in solving your challenges with the XenonStack team?
Get Started

Tell us about you and your priorities so we can prepare the right conversation. It takes about 2 minutes.

Please Select your Industry
Banking
Fintech
Payment Providers
Wealth Management
Discrete Manufacturing
Semiconductor
Machinery Manufacturing / Automation
Appliances / Electrical / Electronics
Elevator Manufacturing
Defense & Space Manufacturing
Computers & Electronics / Industrial Machinery
Motor Vehicle Manufacturing
Food and Beverages
Distillery & Wines
Beverages
Shipping
Logistics
Mobility (EV / Public Transport)
Energy & Utilities
Hospitality
Digital Gaming Platforms
SportsTech with AI
Public Safety - Explosives
Public Safety - Firefighting
Public Safety - Surveillance
Public Safety - Others
Media Platforms
City Operations
Airlines & Aviation
Defense Warfare & Drones
Robotics Engineering
Drones Manufacturing
AI Labs for Colleges
AI MSP / Quantum / AGI Institutes
Retail Apparel and Fashion

Continue