Welcome to the Linux Foundation Forum!

LFD259 - Lab 2.2 - Can't join cluster from worker node

I can't seem to get past step 11.

I have a VM using ubuntu server 26 serving as my Control Panel, and I have a second (physical) machine running Ubuntu Server 24 as my Worker node.

I am using the sudo kubeadm join .... command that I got from running the installation script in my control plane, and I am getting multiple issues:

  1. Port 10250 in use.
    It looks like there is a kubelite process running on that port. Can't get that to be killed, it restarts automatically. I added the --ignore-preflight-errors=Port-10250 flag, to try and force it to move on.

  2. Stuck in TLS Bootstrap phase
    With the flag above, it moves up until the TLS Bootstrap phase, but it can't finish it. No This is the available journalctl log:

Jun 30 12:12:17 worker kubelet[296750]: E0630 12:12:17.635917 296750 bootstrap.go:242] "Unhandled Error" err="unable to read existing bootstrap client config from /etc/kubernetes/kubelet.conf: invalid configuration: [unable to read client-cert /var/lib/kubelet/pki/kubelet-client-current.pem for default-auth due to open /var/lib/kubelet/pki/kubelet-client-current.pem: no such file or directory, unable to read client-key /var/lib/kubelet/pki/kubelet-client-current.pem for default-auth due to open /var/lib/kubelet/pki/kubelet-client-current.pem: no such file or directory]" logger="UnhandledError"
Jun 30 12:12:17 worker kubelet[296750]: E0630 12:12:17.635965 296750 run.go:72] "command failed" err="failed to run Kubelet: unable to load bootstrap kubeconfig: stat /etc/kubernetes/bootstrap-kubelet.conf: no such file or directory"

PS: Is there no way to post this directly in the class forum?? I can't figure out any way to start a new discussion directly there...

Comments

  • chrispokorni
    chrispokorni Posts: 2,612

    Hi @jlouceiro,

    PS: Is there no way to post this directly in the class forum?? I can't figure out any way to start a new discussion directly there...

    The class forum has been discontinued. All cloud native related discussions should be posted in the Cloud & Containers Training category.

    As far as the join issue, I see the complexity of your setup getting in the way.

    Connecting a physical system with a VM introduces networking challenges that are beyond the scope of this course's lab environment setup instructions. Consistency is key in the setup - two identical VMs on the same private subnet, no firewall between them should get you started.

    I also recommend OS consistency between your two systems - Ubuntu 24.04 LTS (server) on both. The labs have not yet been tested on Ubuntu 26.

    The port in use error is common when the join command is executed multiple times in sequence. If it fails on the first run, re-running it will generate more errors. When a re-run is required, perform a cleanup on the target system (the worker in this case) with sudo kubeadm reset, then the worker system will be ready for a new join attempt. The first join failed most likely because of the complexity of your setup.

    Regards,
    -Chris

  • jlouceiro
    jlouceiro Posts: 3

    Thanks for the feedback @chrispokorni

    I eventually found a solution. I did have to kill the process on :10250.

    There was a sort of a dormant kubelite process in :10250. I tried killing it, but (I'm assuming here) it was being relaunched every time the kubelet.service was restarted by systemd.
    Also, that kubelite process was not being terminated by sudo kubeadm reset, so I had to manually kill it after calling reset.

    After making sure that kubelite was not being spawned, running the sudo kubeadm join command worked with no problems.

  • chrispokorni
    chrispokorni Posts: 2,612

    Hi @jlouceiro,

    A small detail worth mentioning - LF staff will assist with help in troubleshooting lab exercises followed as they are presented in the lab guide - the setup recommended above and Kubernetes cluster bootstrapped with kubeadm per the scripts included in the course resources. Alternative installation methods and third patry components (such as kubelite), and any conflicts they may cause on your systems, are not supported.

    Regards,
    -Chris

  • jlouceiro
    jlouceiro Posts: 3

    Yeah, I took a step a bit too big.

    I thought kubelite was being spawned by the kubelet process, but after searching for what it actually was, I figured out it's part of microk8s, which I had installed while getting Ubuntu on my secondary laptop. After uninstalling it, it worked fine.

    I appreciate your support, @chrispokorni. I will keep testing my patience with this setup, taking the chance to figure out a bit more about all this networking shenanigans, but I'll keep in mind your note.

    Best regards

Categories

Upcoming Training