1. 程式人生 > >k8s 1.9.1 centos7 install 離線安裝

k8s 1.9.1 centos7 install 離線安裝

article sudo -a blog .net 密碼 persist per star

參考 http://blog.csdn.net/acxlm/article/details/79069468

遇到的問題及解決:

1. 直接用aliyun docker 可以用最新的, 我用的docker 17.12

#aliyun

mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.back

wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

#docker yum

sudo yum install -y yum-utils device-mapper-persistent-data lvm2

sudo yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo

sudo yum makecache fast

sudo yum -y install docker-ce

sudo service docker start

2. 關閉swap;

3. 關閉selinux

4. cat <<EOF > /etc/sysctl.d/k8s.conf

net.bridge.bridge-nf-call-ip6tables = 1

net.bridge.bridge-nf-call-iptables = 1

EOF

5.

cat << EOF > /etc/docker/daemon.json

{

"exec-opts": ["native.cgroupdriver=systemd"]

}

EOF

6. 鏈接: https://pan.baidu.com/s/1hukuN6O 密碼: 6ehe

The connection to the server localhost:8080 was refused ,解決

export KUBECONFIG=/etc/kubernetes/admin.conf

就是配置沒生效

7. 加入node 時 復制的不要有空格回車

k8s 1.9.1 centos7 install 離線安裝