Networking Guide

Network architecture and configuration guides
You're viewing a development version of manager, the latest released version is v1.4.1
Go to the latest released version

Network Architecture

Physical Network

Each cluster node must have at least one network interface card (NIC) configured as the default gateway. If the node lacks a pre-configured default route, it must be established prior to installation.

K3s requires a default route to auto-detect the node’s primary IP and for kube-proxy ClusterIP routing to function properly. If no default route exists, create a dummy interface as a workaround:

ip link add dummy0 type dummy
ip link set dummy0 up
ip addr add 203.0.113.254/31 dev dummy0
ip route add default via 203.0.113.255 dev dummy0 metric 1000

Overlay Network

Kubernetes creates virtual network interfaces for pods that are typically not associated with any specific firewalld zone. The cluster uses the following network ranges:

NetworkCIDRPurpose
Pod10.42.0.0/16Inter-pod communication
Service10.43.0.0/16Kubernetes service discovery

Firewall regulations should target the primary physical interface. The overlay network traffic is handled by Flannel VXLAN.

Port Requirements

Inter-Node Communication

The following ports must be permitted between all cluster nodes for Kubernetes and cluster infrastructure:

PortProtocolSourceDestinationPurpose
2379-2380TCPServer nodesServer nodesetcd cluster communication
6443TCPAll nodesServer nodesKubernetes API server
8472UDPAll nodesAll nodesFlannel VXLAN overlay network
10250TCPAll nodesAll nodesKubelet metrics and management
5001TCPAll nodesServer nodesSpegel registry mirror
9500-9503TCPAll nodesAll nodesLonghorn management API
8500-8504TCPAll nodesAll nodesLonghorn agent communication
10000-30000TCPAll nodesAll nodesLonghorn data replication
3260TCPAll nodesAll nodesLonghorn iSCSI
2049TCPAll nodesAll nodesLonghorn RWX (NFS)

Application Services Ports

The following ports must be accessible for application services within the cluster:

PortProtocolService
6379TCPRedis
9093TCPAlertmanager
9095TCPKafka
8086TCPTelegraf (InfluxDB v2 listener)

External Access Ports

The following ports must be accessible from external clients to cluster nodes:

PortProtocolService
80TCPHTTP ingress (Optional, redirects to HTTPS)
443TCPHTTPS ingress (Required, all services)
9095TCPKafka (external client connections)
6379TCPRedis (external client connections)
8125TCP/UDPTelegraf (metrics collection)

Network Configuration Guides

Deployment Type

Choose the guide that matches your deployment architecture:

GuideDescriptionWho Should Use This
Configuring Segregated NetworksMulti-NIC deployments with air-gapped cluster backplaneMost users - If you have separate interfaces for cluster traffic and external internet access
Shared Interface SetupSingle-NIC deployments where all traffic shares one interfaceUsers with a single network interface for both cluster traffic and external access

Not sure which to use? If you have explicitly separate interfaces for cluster communication and external access, start with Configuring Segregated Networks. Only use the shared interface guide if your hardware is limited to a single NIC.


Shared Interface Network Setup

Network configuration for standard single-NIC deployments where all traffic shares a single interface.

Configuring Segregated Networks

Multi-NIC deployment guide for air-gapped or segregated network setups