- Getting Started with Kubernetes
- Jonathan Baier Jesse White
- 203字
- 2021-06-10 19:47:02
Installing Kubernetes components (kubelet and kubeadm)
Next, we will need to SSH into all four of the instances and install the Kubernetes components.
As the root user, perform the following steps on all four instances:
- Update the packages and install the apt-transport-https package so that we can download from sources that use HTTPS:
$ apt-get update
$ apt-get install -y apt-transport-https
- Install the Google Cloud public key:
$ curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg |
apt-key add -
- Next, let's set up the repository:
cat <<EOF >/etc/apt/sources.list.d/kubernetes.list
deb http://apt.kubernetes.io/ kubernetes-xenial main
EOF
apt-get update
apt-get install -y kubelet kubeadm kubectl docker.io kubernetes-cni
You'll need to make sure that the cgroup driver used by the kubelet on the master node is configured correctly to work with Docker. Make sure you're on the master node, then run the following:
docker info | grep -i cgroup
cat /etc/systemd/system/kubelet.service.d/10-kubeadm.conf
If these items don't match, you're going to need to change the kubelet configuration to match the Docker driver. Running sed -i "s/cgroup-driver=systemd/cgroup-driver=cgroupfs/g" /etc/systemd/system/kubelet.service.d/10-kubeadm.conf should fix the settings, or you can manually open the systemd file and add the correct flag to the appropriate environment. After that's complete, restart the service:
$ systemctl daemon-reload
$ systemctl restart kubelet
- 虛擬儀器設計測控應用典型實例
- Hands-On Artificial Intelligence on Amazon Web Services
- 大數據專業英語
- 程序設計缺陷分析與實踐
- UTM(統一威脅管理)技術概論
- 具比例時滯遞歸神經網絡的穩定性及其仿真與應用
- 學會VBA,菜鳥也高飛!
- Azure PowerShell Quick Start Guide
- 筆記本電腦維修之電路分析基礎
- Learning Cassandra for Administrators
- Flash CS5二維動畫設計與制作
- 超好玩的Python少兒編程
- R Statistics Cookbook
- Building Smart Drones with ESP8266 and Arduino
- Adobe Edge Quickstart Guide