The Etcd datastore
We explained that kube-apiserver
is a stateless API that can be scaled horizontally. However, it is necessary for kube-apiserver
to store the state of the cluster somewhere, such as the number of containers created, on which machines, the names of the pods, which Docker images they use, and more. To achieve that, it uses the Etcd
database.
The role of the Etcd datastore
Etcd
is part of the control plane. The kube-apiserver
component relies on a distributed NoSQL database called Etcd
. Strictly speaking, Etcd
is not a component of the Kubernetes project. As you might have gathered, Etcd
is not named according to the same nomenclature as the other components (kube*
). This is because Etcd
is not actually a Kubernetes project but a project completely independent of Kubernetes.
Instead of using a full-featured relational database such as MySQL or PostgreSQL, Kubernetes relies on this NoSQL distributed datastore called Etcd
to store its state persistently. Etcd...