Skip to content

Commit af0e08c

Browse files
robert-croninTim Bannisternetwork-charles
authored
Clarify cluster diagram as one possible reference architecture (#47164)
* Clarify cluster diagram as one possible reference architecture * Update content/en/docs/concepts/architecture/_index.md Co-authored-by: Tim Bannister <[email protected]> * Update content/en/docs/concepts/architecture/_index.md Co-authored-by: Tim Bannister <[email protected]> * Update content/en/docs/concepts/architecture/_index.md Co-authored-by: Tim Bannister <[email protected]> * Improve organization of cluster architecture content * Architecture concepts: fix grammar and improve clarity Co-authored-by: Charles Uneze <[email protected]> * Architecture concepts and overview pages refactor Improves clarity and consistency with existing documentation Co-authored-by: Tim Bannister <[email protected]> * Improve organization of cluster architecture content * Improve organization of cluster architecture content Co-authored-by: Tim Bannister <[email protected]> --------- Co-authored-by: Tim Bannister <[email protected]> Co-authored-by: Charles Uneze <[email protected]>
1 parent 9d0fbc5 commit af0e08c

File tree

2 files changed

+199
-108
lines changed

2 files changed

+199
-108
lines changed

content/en/docs/concepts/architecture/_index.md

Lines changed: 160 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,163 @@ description: >
55
The architectural concepts behind Kubernetes.
66
---
77

8-
{{< figure src="/images/docs/kubernetes-cluster-architecture.svg" alt="Components of Kubernetes" caption="Kubernetes cluster architecture" class="diagram-large" >}}
8+
A Kubernetes cluster consists of a control plane plus a set of worker machines, called nodes, that run containerized applications. Every cluster needs at least one worker node in order to run Pods.
9+
10+
The worker node(s) host the Pods that are the components of the application workload. The control plane manages the worker nodes and the Pods in the cluster. In production environments, the control plane usually runs across multiple computers and a cluster usually runs multiple nodes, providing fault-tolerance and high availability.
11+
12+
This document outlines the various components you need to have for a complete and working Kubernetes cluster.
13+
14+
{{< figure src="/images/docs/kubernetes-cluster-architecture.svg" alt="The control plane (kube-apiserver, etcd, kube-controller-manager, kube-scheduler) and several nodes. Each node is running a kubelet and kube-proxy."
15+
title="Kubernetes cluster components"
16+
caption="**Note:** This diagram presents an example reference architecture for a Kubernetes cluster. The actual distribution of components can vary based on specific cluster setups and requirements." class="diagram-large" >}}
17+
18+
## Control plane components
19+
20+
The control plane's components make global decisions about the cluster (for example, scheduling), as well as detecting and responding to cluster events (for example, starting up a new {{< glossary_tooltip text="pod" term_id="pod">}} when a Deployment's `{{< glossary_tooltip text="replicas" term_id="replica" >}}` field is unsatisfied).
21+
22+
Control plane components can be run on any machine in the cluster. However, for simplicity, setup scripts typically start all control plane components on the same machine, and do not run user containers on this machine. See [Creating Highly Available clusters with kubeadm](/docs/setup/production-environment/tools/kubeadm/high-availability/) for an example control plane setup that runs across multiple machines.
23+
24+
### kube-apiserver
25+
26+
{{< glossary_definition term_id="kube-apiserver" length="all" >}}
27+
28+
### etcd
29+
30+
{{< glossary_definition term_id="etcd" length="all" >}}
31+
32+
### kube-scheduler
33+
34+
{{< glossary_definition term_id="kube-scheduler" length="all" >}}
35+
36+
### kube-controller-manager
37+
38+
{{< glossary_definition term_id="kube-controller-manager" length="all" >}}
39+
40+
There are many different types of controllers. Some examples of them are:
41+
42+
- Node controller: Responsible for noticing and responding when nodes go down.
43+
- Job controller: Watches for Job objects that represent one-off tasks, then creates Pods to run those tasks to completion.
44+
- EndpointSlice controller: Populates EndpointSlice objects (to provide a link between Services and Pods).
45+
- ServiceAccount controller: Create default ServiceAccounts for new namespaces.
46+
47+
The above is not an exhaustive list.
48+
49+
### cloud-controller-manager
50+
51+
{{< glossary_definition term_id="cloud-controller-manager" length="short" >}}
52+
53+
The cloud-controller-manager only runs controllers that are specific to your cloud provider. If you are running Kubernetes on your own premises, or in a learning environment inside your own PC, the cluster does not have a cloud controller manager.
54+
55+
As with the kube-controller-manager, the cloud-controller-manager combines several logically independent control loops into a single binary that you run as a single process. You can scale horizontally (run more than one copy) to improve performance or to help tolerate failures.
56+
57+
The following controllers can have cloud provider dependencies:
58+
59+
- Node controller: For checking the cloud provider to determine if a node has been deleted in the cloud after it stops responding
60+
- Route controller: For setting up routes in the underlying cloud infrastructure
61+
- Service controller: For creating, updating and deleting cloud provider load balancers
62+
63+
## Node components
64+
65+
Node components run on every node, maintaining running pods and providing the Kubernetes runtime environment.
66+
67+
### kubelet
68+
69+
{{< glossary_definition term_id="kubelet" length="all" >}}
70+
71+
### kube-proxy (optional) {#kube-proxy}
72+
73+
{{< glossary_definition term_id="kube-proxy" length="all" >}}
74+
If you use a [network plugin](#network-plugins) that implements packet forwarding for Services
75+
by itself, and providing equivalent behavior to kube-proxy, then you do not need to run
76+
kube-proxy on the nodes in your cluster.
77+
78+
### Container runtime
79+
80+
{{< glossary_definition term_id="container-runtime" length="all" >}}
81+
82+
## Addons
83+
84+
Addons use Kubernetes resources ({{< glossary_tooltip term_id="daemonset" >}}, {{< glossary_tooltip term_id="deployment" >}}, etc) to implement cluster features. Because these are providing cluster-level features, namespaced resources for addons belong within the `kube-system` namespace.
85+
86+
Selected addons are described below; for an extended list of available addons, please see [Addons](/docs/concepts/cluster-administration/addons/).
87+
88+
### DNS
89+
90+
While the other addons are not strictly required, all Kubernetes clusters should have [cluster DNS](/docs/concepts/services-networking/dns-pod-service/), as many examples rely on it.
91+
92+
Cluster DNS is a DNS server, in addition to the other DNS server(s) in your environment, which serves DNS records for Kubernetes services.
93+
94+
Containers started by Kubernetes automatically include this DNS server in their DNS searches.
95+
96+
### Web UI (Dashboard)
97+
98+
[Dashboard](/docs/tasks/access-application-cluster/web-ui-dashboard/) is a general purpose, web-based UI for Kubernetes clusters. It allows users to manage and troubleshoot applications running in the cluster, as well as the cluster itself.
99+
100+
### Container resource monitoring
101+
102+
[Container Resource Monitoring](/docs/tasks/debug/debug-cluster/resource-usage-monitoring/) records generic time-series metrics about containers in a central database, and provides a UI for browsing that data.
103+
104+
### Cluster-level Logging
105+
106+
A [cluster-level logging](/docs/concepts/cluster-administration/logging/) mechanism is responsible for saving container logs to a central log store with a search/browsing interface.
107+
108+
### Network plugins
109+
110+
[Network plugins](/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins) are software components that implement the container network interface (CNI) specification. They are responsible for allocating IP addresses to pods and enabling them to communicate with each other within the cluster.
111+
112+
## Architecture variations
113+
114+
While the core components of Kubernetes remain consistent, the way they are deployed and managed can vary. Understanding these variations is crucial for designing and maintaining Kubernetes clusters that meet specific operational needs.
115+
116+
### Control plane deployment options
117+
118+
The control plane components can be deployed in several ways:
119+
120+
Traditional deployment
121+
: Control plane components run directly on dedicated machines or VMs, often managed as systemd services.
122+
123+
Static Pods
124+
: Control plane components are deployed as static Pods, managed by the kubelet on specific nodes. This is a common approach used by tools like kubeadm.
125+
126+
Self-hosted
127+
: The control plane runs as Pods within the Kubernetes cluster itself, managed by Deployments and StatefulSets or other Kubernetes primitives.
128+
129+
Managed Kubernetes services
130+
: Cloud providers often abstract away the control plane, managing its components as part of their service offering.
131+
132+
### Workload placement considerations
133+
134+
The placement of workloads, including the control plane components, can vary based on cluster size, performance requirements, and operational policies:
135+
136+
- In smaller or development clusters, control plane components and user workloads might run on the same nodes.
137+
- Larger production clusters often dedicate specific nodes to control plane components, separating them from user workloads.
138+
- Some organizations run critical add-ons or monitoring tools on control plane nodes.
139+
140+
### Cluster management tools
141+
142+
Tools like kubeadm, kops, and Kubespray offer different approaches to deploying and managing clusters, each with its own method of component layout and management.
143+
144+
The flexibility of Kubernetes architecture allows organizations to tailor their clusters to specific needs, balancing factors such as operational complexity, performance, and management overhead.
145+
146+
### Customization and extensibility
147+
148+
Kubernetes architecture allows for significant customization:
149+
150+
- Custom schedulers can be deployed to work alongside the default Kubernetes scheduler or to replace it entirely.
151+
- API servers can be extended with CustomResourceDefinitions and API Aggregation.
152+
- Cloud providers can integrate deeply with Kubernetes using the cloud-controller-manager.
153+
154+
The flexibility of Kubernetes architecture allows organizations to tailor their clusters to specific needs, balancing factors such as operational complexity, performance, and management overhead.
155+
156+
## {{% heading "whatsnext" %}}
157+
158+
Learn more about the following:
159+
160+
- [Nodes](/docs/concepts/architecture/nodes/) and [their communication](/docs/concepts/architecture/control-plane-node-communication/)
161+
with the control plane.
162+
- Kubernetes [controllers](/docs/concepts/architecture/controller/).
163+
- [kube-scheduler](/docs/concepts/scheduling-eviction/kube-scheduler/) which is the default scheduler for Kubernetes.
164+
- Etcd's official [documentation](https://etcd.io/docs/).
165+
- Several [container runtimes](/docs/setup/production-environment/container-runtimes/) in Kubernetes.
166+
- Integrating with cloud providers using [cloud-controller-manager](/docs/concepts/architecture/cloud-controller/).
167+
- [kubectl](/docs/reference/generated/kubectl/kubectl-commands) commands.

content/en/docs/concepts/overview/components.md

Lines changed: 39 additions & 107 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@ reviewers:
44
title: Kubernetes Components
55
content_type: concept
66
description: >
7-
A Kubernetes cluster consists of the components that are a part of the control
8-
plane and a set of machines called nodes.
7+
An overview of the key components that make up a Kubernetes cluster.
98
weight: 30
109
card:
1110
title: Components of a cluster
@@ -14,140 +13,73 @@ card:
1413
---
1514

1615
<!-- overview -->
17-
When you deploy Kubernetes, you get a cluster.
18-
{{< glossary_definition term_id="cluster" length="all" prepend="A Kubernetes cluster consists of">}}
1916

20-
This document outlines the various components you need to have for
21-
a complete and working Kubernetes cluster.
17+
This page provides a high-level overview of the essential components that make up a Kubernetes cluster.
2218

2319
{{< figure src="/images/docs/components-of-kubernetes.svg" alt="Components of Kubernetes" caption="The components of a Kubernetes cluster" class="diagram-large" clicktozoom="true" >}}
2420

2521
<!-- body -->
26-
## Control Plane Components
2722

28-
The control plane's components make global decisions about the cluster (for example, scheduling),
29-
as well as detecting and responding to cluster events (for example, starting up a new
30-
{{< glossary_tooltip text="pod" term_id="pod">}} when a Deployment's
31-
`{{< glossary_tooltip text="replicas" term_id="replica" >}}` field is unsatisfied).
23+
## Core Components
3224

33-
Control plane components can be run on any machine in the cluster. However,
34-
for simplicity, setup scripts typically start all control plane components on
35-
the same machine, and do not run user containers on this machine. See
36-
[Creating Highly Available clusters with kubeadm](/docs/setup/production-environment/tools/kubeadm/high-availability/)
37-
for an example control plane setup that runs across multiple machines.
25+
A Kubernetes cluster consists of a control plane and one or more worker nodes. Here's a brief overview of the main components:
3826

39-
### kube-apiserver
27+
### Control Plane Components
4028

41-
{{< glossary_definition term_id="kube-apiserver" length="all" >}}
29+
Manage the overall state of the cluster:
4230

43-
### etcd
31+
[kube-apiserver](/docs/concepts/architecture/#kube-apiserver)
32+
: The core component server that exposes the Kubernetes HTTP API
4433

45-
{{< glossary_definition term_id="etcd" length="all" >}}
34+
[etcd](/docs/concepts/architecture/#etcd)
35+
: Consistent and highly-available key value store for all API server data
4636

47-
### kube-scheduler
37+
[kube-scheduler](/docs/concepts/architecture/#kube-scheduler)
38+
: Looks for Pods not yet bound to a node, and assigns each Pod to a suitable node.
4839

49-
{{< glossary_definition term_id="kube-scheduler" length="all" >}}
40+
[kube-controller-manager](/docs/concepts/architecture/#kube-controller-manager)
41+
: Runs {{< glossary_tooltip text="controllers" term_id="controller" >}} to implement Kubernetes API behavior.
5042

51-
### kube-controller-manager
43+
[cloud-controller-manager](/docs/concepts/architecture/#cloud-controller-manager) (optional)
44+
: Integrates with underlying cloud provider(s)
5245

53-
{{< glossary_definition term_id="kube-controller-manager" length="all" >}}
46+
### Node Components
5447

55-
There are many different types of controllers. Some examples of them are:
48+
Run on every node, maintaining running pods and providing the Kubernetes runtime environment:
5649

57-
* Node controller: Responsible for noticing and responding when nodes go down.
58-
* Job controller: Watches for Job objects that represent one-off tasks, then creates
59-
Pods to run those tasks to completion.
60-
* EndpointSlice controller: Populates EndpointSlice objects (to provide a link between Services and Pods).
61-
* ServiceAccount controller: Create default ServiceAccounts for new namespaces.
50+
[kubelet](/docs/concepts/architecture/#kubelet)
51+
: Ensures that Pods are running, including their containers.
6252

63-
The above is not an exhaustive list.
53+
[kube-proxy](/docs/concepts/architecture/#kube-proxy) (optional)
54+
: Maintains network rules on nodes to implement {{< glossary_tooltip text="Services" term_id="service" >}}
6455

65-
### cloud-controller-manager
56+
[Container runtime](/docs/concepts/architecture/#container-runtime)
57+
: Software responsible for running containers. Read [Container Runtimes](/docs/setup/production-environment/container-runtimes/) to learn more.
6658

67-
{{< glossary_definition term_id="cloud-controller-manager" length="short" >}}
6859

69-
The cloud-controller-manager only runs controllers that are specific to your cloud provider.
70-
If you are running Kubernetes on your own premises, or in a learning environment inside your
71-
own PC, the cluster does not have a cloud controller manager.
60+
{{% thirdparty-content single="true" %}}
7261

73-
As with the kube-controller-manager, the cloud-controller-manager combines several logically
74-
independent control loops into a single binary that you run as a single process. You can
75-
scale horizontally (run more than one copy) to improve performance or to help tolerate failures.
76-
77-
The following controllers can have cloud provider dependencies:
78-
79-
* Node controller: For checking the cloud provider to determine if a node has been deleted in the cloud after it stops responding
80-
* Route controller: For setting up routes in the underlying cloud infrastructure
81-
* Service controller: For creating, updating and deleting cloud provider load balancers
82-
83-
## Node Components
84-
85-
Node components run on every node, maintaining running pods and providing the Kubernetes runtime environment.
86-
87-
### kubelet
88-
89-
{{< glossary_definition term_id="kubelet" length="all" >}}
90-
91-
### kube-proxy
92-
93-
{{< glossary_definition term_id="kube-proxy" length="all" >}}
94-
95-
### Container runtime
96-
97-
{{< glossary_definition term_id="container-runtime" length="all" >}}
62+
Your cluster may require additional software on each node; for example, you might also
63+
run [systemd](https://systemd.io/) on a Linux node to supervise local components.
9864

9965
## Addons
10066

101-
Addons use Kubernetes resources ({{< glossary_tooltip term_id="daemonset" >}},
102-
{{< glossary_tooltip term_id="deployment" >}}, etc)
103-
to implement cluster features. Because these are providing cluster-level features, namespaced resources
104-
for addons belong within the `kube-system` namespace.
105-
106-
Selected addons are described below; for an extended list of available addons, please
107-
see [Addons](/docs/concepts/cluster-administration/addons/).
108-
109-
### DNS
110-
111-
While the other addons are not strictly required, all Kubernetes clusters should have
112-
[cluster DNS](/docs/concepts/services-networking/dns-pod-service/), as many examples rely on it.
113-
114-
Cluster DNS is a DNS server, in addition to the other DNS server(s) in your environment,
115-
which serves DNS records for Kubernetes services.
116-
117-
Containers started by Kubernetes automatically include this DNS server in their DNS searches.
118-
119-
### Web UI (Dashboard)
120-
121-
[Dashboard](/docs/tasks/access-application-cluster/web-ui-dashboard/) is a general purpose,
122-
web-based UI for Kubernetes clusters. It allows users to manage and troubleshoot applications
123-
running in the cluster, as well as the cluster itself.
124-
125-
### Container Resource Monitoring
126-
127-
[Container Resource Monitoring](/docs/tasks/debug/debug-cluster/resource-usage-monitoring/)
128-
records generic time-series metrics
129-
about containers in a central database, and provides a UI for browsing that data.
67+
Addons extend the functionality of Kubernetes. A few important examples include:
13068

131-
### Cluster-level Logging
69+
[DNS](/docs/concepts/architecture/#dns)
70+
: For cluster-wide DNS resolution
13271

133-
A [cluster-level logging](/docs/concepts/cluster-administration/logging/) mechanism is responsible for
134-
saving container logs to a central log store with search/browsing interface.
72+
[Web UI](/docs/concepts/architecture/#web-ui-dashboard) (Dashboard)
73+
: For cluster management via a web interface
13574

136-
### Network Plugins
75+
[Container Resource Monitoring](/docs/concepts/architecture/#container-resource-monitoring)
76+
: For collecting and storing container metrics
13777

138-
[Network plugins](/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins) are software
139-
components that implement the container network interface (CNI) specification. They are responsible for
140-
allocating IP addresses to pods and enabling them to communicate with each other within the cluster.
78+
[Cluster-level Logging](/docs/concepts/architecture/#cluster-level-logging)
79+
: For saving container logs to a central log store
14180

81+
## Flexibility in Architecture
14282

143-
## {{% heading "whatsnext" %}}
83+
Kubernetes allows for flexibility in how these components are deployed and managed. The architecture can be adapted to various needs, from small development environments to large-scale production deployments.
14484

145-
Learn more about the following:
146-
* [Nodes](/docs/concepts/architecture/nodes/) and [their communication](/docs/concepts/architecture/control-plane-node-communication/)
147-
with the control plane.
148-
* Kubernetes [controllers](/docs/concepts/architecture/controller/).
149-
* [kube-scheduler](/docs/concepts/scheduling-eviction/kube-scheduler/) which is the default scheduler for Kubernetes.
150-
* Etcd's official [documentation](https://etcd.io/docs/).
151-
* Several [container runtimes](/docs/setup/production-environment/container-runtimes/) in Kubernetes.
152-
* Integrating with cloud providers using [cloud-controller-manager](/docs/concepts/architecture/cloud-controller/).
153-
* [kubectl](/docs/reference/generated/kubectl/kubectl-commands) commands.
85+
For more detailed information about each component and various ways to configure your cluster architecture, see the [Cluster Architecture](/docs/concepts/architecture/) page.

0 commit comments

Comments
 (0)