0

First, sorry for my bad English.

I want to execute k8s with Vagrant

executed commands to install k8s.

cat <<EOF > /etc/sysctl.d/k8s.conf
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
EOF

cat > /etc/modules-load.d/containerd.conf <<EOF
overlay
br_netfilter
EOF

modprobe overlay
modprobe br_netfilter

cat > /etc/sysctl.d/99-kubernetes-cri.conf <<EOF
net.bridge.bridge-nf-call-iptables  = 1
net.ipv4.ip_forward                 = 1
net.bridge.bridge-nf-call-ip6tables = 1
EOF

apt-get install -y apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -

add-apt-repository \
    "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
    $(lsb_release -cs) \
    stable"

apt-get install -y containerd.io

mkdir -p /etc/containerd
containerd config default | tee /etc/containerd/config.toml
systemctl restart containerd

apt-get install -y apt-transport-https curl
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
cat <<EOF | tee /etc/apt/sources.list.d/kubernetes.list
deb https://apt.kubernetes.io/ kubernetes-xenial main
EOF

apt install -y kubelet kubeadm kubectl --allow-change-held-packages
apt-mark hold kubelet kubeadm kubectl

cat << EOF | tee /etc/default/kubelet
Environment="KUBELET_EXTRA_ARGS=--fail-swap-on=false"
EOF

systemctl daemon-reload
systemctl restart kubelet

result for systemctl status kubelet

and journalctl -xeu kubelet

at the moment, I'm executed swapoff -a.

what is mean for exit-code 1.

why I'm failed start kubelet?

and you can make sense of my English?

nrs3
  • 1
  • 1
    Hi nrs3 welcome to S.F. Please don't post textual content as screenshots; it impairs searching, is hard to read, and is explicitly mentioned in the [how to ask](https://serverfault.com/help/how-to-ask) page. Separately, don't expect **one line** of log output to help anyone to help you. You will need more lines for anyone to know. Good luck – mdaniel May 31 '22 at 04:33

0 Answers0