ansible-role-kubernetes icon indicating copy to clipboard operation
ansible-role-kubernetes copied to clipboard

Error joining Kubernetes node: "couldn't validate the identity of the API Server

Open galarconm opened this issue 1 month ago • 0 comments

When running the grycap.kubernetes : Add node to kube cluster task on Ubuntu 22.04 LTS with Kubernetes v1.24.17, the process fails with the following error:

error execution phase preflight: couldn't validate the identity of the API Server: Get "https://kubeserver:6443/api/v1/namespaces/kube-public/configmaps/cluster-info?timeout=10s": dial tcp 10.10.1.6:6443: connect: connection refused

TASK [grycap.kubernetes : Add node to kube cluster] **************************** fatal: [10.10.1.18_2]: FAILED! => {"changed": true, "cmd": ["kubeadm", "join", "--config", "/tmp/kubeadm-config.yml"], "delta": "0:05:00.194001", "end": "2025-01-17 10:44:48.139352", "msg": "non-zero return code", "rc": 1, "start": "2025-01-17 10:39:47.945351", "stderr": "error execution phase preflight: couldn't validate the identity of the API Server: Get \"https://kubeserver:6443/api/v1/namespaces/kube-public/configmaps/cluster-info?timeout=10s\": dial tcp 10.10.1.6:6443: connect: connection refused\nTo see the stack trace of this error execute with --v=5 or higher", "stderr_lines": ["error execution phase preflight: couldn't validate the identity of the API Server: Get \"https://kubeserver:6443/api/v1/namespaces/kube-public/configmaps/cluster-info?timeout=10s\": dial tcp 10.10.1.6:6443: connect: connection refused", "To see the stack trace of this error execute with --v=5 or higher"], "stdout": "[preflight] Running pre-flight checks", "stdout_lines": ["[preflight] Running pre-flight checks"]}

galarconm avatar Jan 18 '25 12:01 galarconm