To run anything with kubernetes we need to define a configuration for our cluster first. Easy way is to use minikube. We won't use that. There are at least 3 executables you would use: kubelet - an application that runs on every node allowing remote interaction kubeadm kubectl - with it you can control the cluster (on local or remote machines), ex. on your computer which might be NOT a part of cluster... in our case it would connect to local host So go to https://kubernetes.io/docs/setup/production-environment/tools/kubeadm/install-kubeadm/ then execute # systemctl restart kubelet # we are trying to restart kubelet... I already had this working # journalctl -xe # wait... something is not right let's check the logs # swapoff -a # it was refusing to run on my system as I had swap enabled thus I'm disabling the swap # service kubelet status #checking kubelet status... and it is still not starting... in fact restarting all the time # service kubelet stop # no need t...
I'm back to the kubernetes initialization. When trying to run `kubeadm init` I'm getting a warning about cgroupfs which should be replaced with systemd. I'm using ubuntu with systemd. https://kubernetes.io/docs/setup/cri The documentation states that having systemd OS and cgroupfs for k8s leads to having 2 cgroup managers and could lead to conflicts . As a result I'm switching to systemd. My previous problem with swap is gone as my system has now 72 GB of RAM and no swap at all (by my design). But I'm on a new system. I have created a new file /etc/docker/daemon.json and set driver there to systemd. Followed by `service docker restart`. `kubeadm init`... I have some more warnings: ethtool, socat, conntrack and kubelet service are missing. `apt install -y ethtool socat conntrack` - lucky this is already available on my system and I can install whatever came with it (no need for newest-possible-predevelop sources). Now only kubelet service is missing... ` sudo vim /et...
Lets check the kubeadm version: `kubeadm version` kubeadm version: &version.Info{Major:"1", Minor:"19+", GitVersion:" v1.19.0-beta.2.517 +ec36ff40016e1e", GitCommit:"ec36ff40016e1ea612ae364b3b550cd31dd04651", GitTreeState:"clean", BuildDate:"2020-07-06T23:48:41Z", GoVersion:"go1.14.4", Compiler:"gc", Platform:"linux/amd64"} So I'm running on the edge with unreleased code... with beta + some change. `kubelet --version` Kubernetes v1.19.0-beta.2.517 +ec36ff40016e1e Have you noticed some inconsistency in the API? :) This code sux so much... I love and hate kubernetes at the same time. `kubeadm init` W0708 00:36:10.404244 268603 configset.go:293] WARNING: kubeadm cannot validate component configs for API groups [kubelet.config.k8s.io kubeproxy.config.k8s.io] [init] Using Kubernetes version: v1.18.5 [preflight] Running pre-flight checks error execution phase preflight: [preflight] Some fatal ...
Comments
Post a Comment