Trying to deploy Kubernetes on AWS EC2 instance. I'm seeing the following errors/warning when running sudo kubeadm init --pod-network-cidr=10.244.0.0/16 --ignore-preflight-errors=all
Errors:
[WARNING CRI]: container runtime is not running: output: time="2023-06-23T03:15:01Z" level=fatal msg="validate service connection: CRI v1 runtime API is not implemented for endpoint "unix:///var/run/containerd/containerd.sock": rpc error: code = Unimplemented desc = unknown service runtime.v1.RuntimeService"
, error: exit status 1
[kubelet-check] Initial timeout of 40s passed.
[kubelet-check] It seems like the kubelet isn't running or healthy.
[kubelet-check] The HTTP call equal to 'curl -sSL
http://localhost:10248/healthz' failed with error: Get
"http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect:
connection refused. [kubelet-check] It seems like the kubelet isn't
running or healthy. [kubelet-check] The HTTP call equal to 'curl -sSL
http://localhost:10248/healthz' failed with error: Get
"http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect:
connection refused. [kubelet-check] It seems like the kubelet isn't
running or healthy. [kubelet-check] The HTTP call equal to 'curl -sSL
http://localhost:10248/healthz' failed with error: Get
"http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect:
connection refused. [kubelet-check] It seems like the kubelet isn't
running or healthy. [kubelet-check] The HTTP call equal to 'curl -sSL
http://localhost:10248/healthz' failed with error: Get
"http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect:
connection refused. [kubelet-check] It seems like the kubelet isn't
running or healthy. [kubelet-check] The HTTP call equal to 'curl -sSL
http://localhost:10248/healthz' failed with error: Get
"http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect:
connection refused.
Unfortunately, an error has occurred:
timed out waiting for the condition
This error is likely caused by:
- The kubelet is not running
- The kubelet is unhealthy due to a misconfiguration of the node in some way (required cgroups disabled)
If you are on a systemd-powered system, you can try to troubleshoot
the error with the following commands:
- 'systemctl status kubelet'
- 'journalctl -xeu kubelet'
Additionally, a control plane component may have crashed or exited
when started by the container runtime. To troubleshoot, list all
containers using your preferred container runtimes CLI. Here is one
example how you may list all running Kubernetes containers by using
crictl:
- 'crictl --runtime-endpoint unix:///var/run/containerd/containerd.sock ps -a | grep kube | grep -v
pause'
Once you have found the failing container, you can inspect its logs with:
- 'crictl --runtime-endpoint unix:///var/run/containerd/containerd.sock logs CONTAINERID' error
execution phase wait-control-plane: couldn't initialize a Kubernetes
cluster
I'm not sure where to begin with, Kubectl version.
{
"clientVersion": {
"major": "1",
"minor": "27",
"gitVersion": "v1.27.3",
"gitCommit": "25b4e43193bcda6c7328a6d147b1fb73a33f1598",
"gitTreeState": "clean",
"buildDate": "2023-06-14T09:53:42Z",
"goVersion": "go1.20.5",
"compiler": "gc",
"platform": "linux/amd64"
},
"kustomizeVersion": "v5.0.1"
}
Any suggestions?