Skip to content

Commit 0a4887e

Browse files
authored
Merge pull request #29699 from PushkarJ/netw-ports-protocols
Add a ports and protocols reference page
2 parents cd0b3b5 + 7655d8d commit 0a4887e

File tree

3 files changed

+45
-25
lines changed

3 files changed

+45
-25
lines changed

content/en/docs/reference/_index.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,8 @@ client libraries:
6464
* [Scheduler Policies](/docs/reference/scheduling/policies)
6565
* [Scheduler Profiles](/docs/reference/scheduling/config#profiles)
6666

67+
* List of [ports and protocols](/docs/reference/ports-and-protocols/) that
68+
should be open on control plane and worker nodes
6769
## Config APIs
6870

6971
This section hosts the documentation for "unpublished" APIs which are used to
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
---
2+
title: Ports and Protocols
3+
content_type: reference
4+
weight: 50
5+
---
6+
7+
When running Kubernetes in an environment with strict network boundaries, such
8+
as on-premises datacenter with physical network firewalls or Virtual
9+
Networks in Public Cloud, it is useful to be aware of the ports and protocols
10+
used by Kubernetes components
11+
12+
## Control plane
13+
14+
| Protocol | Direction | Port Range | Purpose | Used By |
15+
|----------|-----------|------------|-------------------------|---------------------------|
16+
| TCP | Inbound | 6443 | Kubernetes API server | All |
17+
| TCP | Inbound | 2379-2380 | etcd server client API | kube-apiserver, etcd |
18+
| TCP | Inbound | 10250 | Kubelet API | Self, Control plane |
19+
| TCP | Inbound | 10259 | kube-scheduler | Self |
20+
| TCP | Inbound | 10257 | kube-controller-manager | Self |
21+
22+
Although etcd ports are included in control plane section, you can also host your own
23+
etcd cluster externally or on custom ports.
24+
25+
## Worker node(s) {#node}
26+
27+
| Protocol | Direction | Port Range | Purpose | Used By |
28+
|----------|-----------|-------------|-----------------------|-------------------------|
29+
| TCP | Inbound | 10250 | Kubelet API | Self, Control plane |
30+
| TCP | Inbound | 30000-32767 | NodePort Services† | All |
31+
32+
† Default port range for [NodePort Services](/docs/concepts/services-networking/service/).
33+
34+
All default port numbers can be overridden. When custom ports are used those
35+
ports need to be open instead of defaults mentioned here.
36+
37+
One common example is API server port that is sometimes switched
38+
to 443. Alternatively, the default port is kept as is and API server is put
39+
behind a load balancer that listens on 443 and routes the requests to API server
40+
on the default port.

content/en/docs/setup/production-environment/tools/kubeadm/install-kubeadm.md

Lines changed: 3 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -67,31 +67,9 @@ sudo sysctl --system
6767
For more details please see the [Network Plugin Requirements](/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins/#network-plugin-requirements) page.
6868

6969
## Check required ports
70-
71-
### Control-plane node(s)
72-
73-
| Protocol | Direction | Port Range | Purpose | Used By |
74-
|----------|-----------|------------|-------------------------|---------------------------|
75-
| TCP | Inbound | 6443\* | Kubernetes API server | All |
76-
| TCP | Inbound | 2379-2380 | etcd server client API | kube-apiserver, etcd |
77-
| TCP | Inbound | 10250 | kubelet API | Self, Control plane |
78-
| TCP | Inbound | 10251 | kube-scheduler | Self |
79-
| TCP | Inbound | 10252 | kube-controller-manager | Self |
80-
81-
### Worker node(s)
82-
83-
| Protocol | Direction | Port Range | Purpose | Used By |
84-
|----------|-----------|-------------|-----------------------|-------------------------|
85-
| TCP | Inbound | 10250 | kubelet API | Self, Control plane |
86-
| TCP | Inbound | 30000-32767 | NodePort Services† | All |
87-
88-
† Default port range for [NodePort Services](/docs/concepts/services-networking/service/).
89-
90-
Any port numbers marked with * are overridable, so you will need to ensure any
91-
custom ports you provide are also open.
92-
93-
Although etcd ports are included in control-plane nodes, you can also host your own
94-
etcd cluster externally or on custom ports.
70+
These
71+
[required ports](/docs/reference/ports-and-protocols/)
72+
need to be open in order for Kubernetes components to communicate with each other.
9573

9674
The pod network plugin you use (see below) may also require certain ports to be
9775
open. Since this differs with each pod network plugin, please see the

0 commit comments

Comments
 (0)