DEV Community

Cover image for Before there was Kubernetes, there was Borg......
kaustubh yerkade
kaustubh yerkade

Posted on

Before there was Kubernetes, there was Borg......

Google built Borg, an internal cluster management and scheduling system that would become one of the most influential pieces of software in computing history. Borg wasn’t just another management tool, it was their cluster operating system.

In the early 2000s, Google had a problem most companies would dream of, their infrastructure was growing too fast. Thousands of servers, millions of jobs, and every team deploying their own workloads manually.

Managing this chaos with scripts and SSH just wasn’t going to cut it.

What Is Borg?

It was build as a brain that controls Google’s data centers.

It tells each machine:

  • Which workloads to run
  • How much CPU, memory, and disk they can use
  • How to restart them automatically if they crash
  • How to balance everything for maximum efficiency

Every search query, YouTube video, Gmail sync, ad service, at some point been orchestrated by Borg.

Borg’s magic lies in scheduling. It packs workloads efficiently across thousands of servers, ensuring high utilization and reliability.

Each cluster is managed by a Borgmaster (the scheduler) and Borglets (agents running on each node).

The master makes decisions; the Borglets execute them.


From Borg to Kubernetes: Open Sourcing the Lessons

After a decade of running Borg internally, Google engineers realized the rest of the world was about to face similar scale problems... especially with the rise of containers.

So in 2014, they open-sourced a reimagined version of Borg’s concepts:
Kubernetes (from the Greek word for “helmsman” or “pilot”).

Kubernetes took Borg’s DNA i.e. resource scheduling, self-healing, job abstraction and made it open, modular, and container-native.

Here’s a simple mapping-

Borg Concept Kubernetes Equivalent Purpose
Job / Task Pod / Deployment Define what runs
Cell Cluster / Namespace Logical group of nodes
Borgmaster API Server + Scheduler Controls the cluster
Borglet Kubelet Node agent that runs containers
Allocation Pod Smallest schedulable unit

Kubernetes is essentially Borg made open-source, modern, and container-aware.

But while Borg was built for Google’s private infrastructure, Kubernetes was built for everyone, to run anywhere : on AWS, Azure, GCP, or even your laptop.

Borg Kubernetes
Built for Google-scale data centers Built for the cloud-native world
Binary executables Containers
Proprietary & internal Open-source & extensible
Centralized design API-driven modular design
Focused on efficiency Focused on portability

Even today, Borg continues to quietly power Google Search, Maps, Ads, and Gmail. Meanwhile, Kubernetes has become the de facto standard for cloud-native infrastructure adopted by everyone from startups to enterprises.

Many Kubernetes clusters today are hosted on Google Cloud, which itself runs on Borg. So in a sense Kubernetes runs on Borg. And the Legacy Lives On..........

Reference-

https://static.googleusercontent.com/media/research.google.com/en//pubs/archive/43438.pdf

https://kubernetes.io/blog/2015/04/borg-predecessor-to-kubernetes/

https://en.wikipedia.org/wiki/Borg_(cluster_manager)

Top comments (0)