Building the largest known Kubernetes cluster, with 130k nodes
49 points
2 days ago
| 8 comments
| cloud.google.com
| HN
hazz99
4 hours ago
[-]
I’m sure this work is very impressive, but these QPS numbers don’t seem particularly high to me, at least compared to existing horizontally scalable service patterns. Why is it hard for the kube control plane to hit these numbers?

For instance, postgres can hit this sort of QPS easily, afaik. It’s not distributed, but I’m sure Vitess could do something similar. The query patterns don’t seem particularly complex either.

Not trying to be reductive - I’m sure there’s some complexity here I’m missing!

reply
phrotoma
2 hours ago
[-]
I am extremely Not A Database Person but I understand that the rationale for Kubernetes adopting etcd as its preferred data store was more about its distributed consistency features and less about query throughput. etcd is slower cause it's doing RAFT things and flushing stuff to disk.

Projects like kine allow K8s users to swap sqlite or postgres in place of etcd which (I assume, please correct me otherwise) would deliver better throughput since those backends don't need to perform consenus operations.

https://github.com/k3s-io/kine

reply
dijit
2 hours ago
[-]
You might not be a database person, but you’re spot on.

A well managed HA postgresql (active/passive) is going to run circles around etcd for kube controlplane operations.

The caveat here is increased risk of downtime, and a much higher management overhead, which is why its not the default.

reply
Sayrus
1 hour ago
[-]
GKE uses Spanner as an etcd replacement.
reply
ZeroCool2u
1 hour ago
[-]
But, and I'm honestly asking, you as a GKE user don't have to manage that spanner instance, right? So, you should in theory be able to just throw higher loads at it and spanner should be autoscaling?
reply
DougBTX
41 minutes ago
[-]
Yes, from the article:

> To support the cluster’s massive scale, we relied on a proprietary key-value store based on Google’s Spanner distributed database... We didn’t witness any bottlenecks with respect to the new storage system and it showed no signs of it not being able to support higher scales.

reply
PunchyHamster
28 minutes ago
[-]
it's not really bottlenecked by the store but by the calculations performed on each pod schedule/creation.

It's basically "take global state of node load and capacity, pick where to schedule it", and I'd imagine probably not running in parallel coz that would be far harder to manage.

reply
senorrib
10 minutes ago
[-]
No a k8s dev, but I feel like this is the answer. K8s isn't usually just scheduling pods round robin or at random. There's a lot of state to evaluate, and the problem of scheduling pods becomes an NP-hard problem similar to bin packing problem. I doubt the implementation tries to be optimal here, but it feels a computationally heavy problem.
reply
yanhangyhy
2 hours ago
[-]
there is a doc about how to do with 1M nodes: https://bchess.github.io/k8s-1m/#_why

so i guess the title is not true?

reply
Thaxll
1 minute ago
[-]
THis is a PoC not backed by a reliable etcd replacement.
reply
arccy
52 minutes ago
[-]
That's simulated using kwok, not real.

> Unfortunately running 1M real kubelets is beyond my budget.

reply
blurrybird
3 hours ago
[-]
reply
cowsandmilk
1 hour ago
[-]
That is 100k vs 130k for Google’s new announcement. I can’t speak as to whether the additional 30k presented new challenges though.
reply
xyse53
4 hours ago
[-]
They mention GCS fuse. We've had nothing but performance and stability problems with this.

We treat it as a best effort alternative when native GCS access isn't possible.

reply
dijit
2 hours ago
[-]
fuse based filesystems in general shouldn’t be treated as production ready in my experience.

They’re wonderful for low volume, low performance and low reliability operations. (browsing, copying, integrating with legacy systems that do not permit native access), but beyond that they consume huge resources and do odd things when the backend is not in its most ideal state.

reply
thundergolfer
23 minutes ago
[-]
AWS Lambda uses FUSE and that’s one of the largest prod systems in the world.
reply
dijit
2 minutes ago
[-]
An option exists, but they prefer you use the block storage API.
reply
rvz
4 hours ago
[-]
> While we don’t yet officially support 130K nodes, we're very encouraged by these findings. If your workloads require this level of scale, reach out to us to discuss your specific needs

Obviously this is a typical experiment at Google on running a K8s cluster at 130K nodes but if there is a company out their that "requires" this scale, I must question their architecture and their infrastructure costs.

But of course someone will always request that they somehow need this sort of scale to run their enterprise app. But once again, let's remind the pre-revenue startups talking about scale before they hit PMF:

Unless you are ready to donate tens of billions of dollars yearly, you do not need this.

You are not Google.

reply
jcims
54 minutes ago
[-]
I work for a mature public company that most people in the US have at least heard of. We're far from the largest in our industry and we run jobs with more than that almost every night. Not via k8s though.
reply
mlnj
2 hours ago
[-]
>You are not Google.

It's literally Google coming out with this capability and how is the criticism still "You are not Google"

reply
Rastonbury
2 hours ago
[-]
The criticism is at pre-PMF startups who believe they need something similar
reply
jakupovic
2 hours ago
[-]
Doing this at anything > 1k nodes is a pain in the butt. We decided to run many <100 nodes clusters rather than a few big ones.
reply
kvrty
1 hour ago
[-]
Same here. Non Kubernetes project originated control plane components start failing beyond a certain limit - your ingress controllers, service meshes etc. So I don't usually take node numbers from these benchmarks seriously for our kind of workloads. We run a bunch of sub-1k node clusters.
reply
liveoneggs
44 minutes ago
[-]
Same. The control plane and various controllers just aren't up to the task.
reply
belter
2 hours ago
[-]
130k nodes...cute...but can Google conquer the ultimate software engineering challenge they warn you about in CS school? A functional online signup flow?
reply
chrisandchris
31 minutes ago
[-]
The could team up with Microsoft, because their signup flow is fine but the login flow is badly broken.
reply
jasonvorhe
2 hours ago
[-]
For what? Access to the control plane API?
reply
belter
2 hours ago
[-]
In general... Try to sign up for their AI services...
reply
zoobab
3 hours ago
[-]
The new mainframe.
reply