CentOS7.5利用Kubeadm安装kubernets1.13.0(国内版)
更新:HHH   时间:2023-1-7


国内版
一、部署Kubernetes1.13.0(无dashboard)
前期准备(all node):
#swapoff -a
#防火墙关闭
!# cat <<EOF > /etc/sysctl.d/k8s.conf
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
EOF
!# sysctl --system
1、解压
all node#tar -zxvf k8s_1.13.0.tar.gz
2、安装软件包并启动docker服务
all node# cd rpm
all node# yum localinstall *.rpm
all node# systemctl start docker
all node# systemctl enable docker
all node# systemctl enable kubelet
3、导入镜像
all node#cd image
all node# docker load -i k8s.gcr.io.basic_1.13.0.tar.gz
google镜像包地址:
链接:https://pan.baidu.com/s/1Lwokd8w7mqBJjG23sQrD2A
提取码:nx2a
4、安装master节点
master#kubeadm init --kubernetes-version=v1.13.0 --pod-network-cidr=10.244.0.0/16 --service-cidr=10.96.0.0/12
待kubeadm 自动安装完成
master#mkdir -p $HOME/.kube
master#cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
master#chown $(id -u):$(id -g) $HOME/.kube/config
master#kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
4、安装node节点
node# kubeadm join ..................................
单节点masterK8s1.13.0部署完成(无dashboard)
5、查看node是否正常
master#kubectl get node



返回云计算教程...