Kubernetes : Install Kubeadm2025/08/25 |
Configure Multi Nodes Kubernetes Cluster. This example is based on the environment like follows. For System requirements, each Node has unique Hostname, MAC address, Product_uuid. +----------------------+ +----------------------+
| [ ctrl.srv.world ] | | [ dlp.srv.world ] |
| Manager Node | | Control Plane |
+-----------+----------+ +-----------+----------+
eth0|10.0.0.25 eth0|10.0.0.30
| |
------------+--------------------------+-----------
| |
eth0|10.0.0.51 eth0|10.0.0.52
+-----------+----------+ +-----------+----------+
| [ node01.srv.world ] | | [ node02.srv.world ] |
| Worker Node#1 | | Worker Node#2 |
+----------------------+ +----------------------+
|
| [1] | On all Kubernetes Cluster Nodes except Manager Node, Change settings for System requirements. |
root@dlp:~# root@dlp:~# apt -y install containerd curl gpg containerd config default | tee /etc/containerd/config.toml root@dlp:~# vi /etc/containerd/config.toml # line 67 : change sandbox_image = "registry.k8s.io/pause:3.10" # line 139 : change SystemdCgroup = true root@dlp:~# systemctl restart containerd.service root@dlp:~# cat > /etc/sysctl.d/99-k8s-cri.conf <<EOF net.bridge.bridge-nf-call-iptables=1 net.bridge.bridge-nf-call-ip6tables=1 net.ipv4.ip_forward=1 EOF root@dlp:~# sysctl --system # disable swap root@dlp:~# swapoff -a root@dlp:~# vi /etc/fstab # comment out #/dev/mapper/debian--vg-swap_1 none swap sw 0 0 |
| [2] | On all Kubernetes Cluster Nodes except Manager Node, Install required packages. |
root@dlp:~# root@dlp:~# curl -fsSL https://pkgs.k8s.io/core:/stable:/v1.33/deb/Release.key | gpg --dearmor -o /etc/apt/keyrings/kubernetes-apt-keyring.gpg root@dlp:~# echo "deb [signed-by=/etc/apt/keyrings/kubernetes-apt-keyring.gpg] https://pkgs.k8s.io/core:/stable:/v1.33/deb/ /" | tee /etc/apt/sources.list.d/kubernetes.list ln -s /opt/cni/bin /usr/lib/cni |
No comments:
Post a Comment