I did command om master node
microk8s add-node
From the node you wish to join to this cluster, run the following:
microk8s join 192.168.0.xxx:25000/token
If the node you are adding is not reachable through the default interface you can use one of the following:
microk8s join 192.168.0.yyy:25000/token
microk8s join 192.168.0.xxx:25000/token
microk8s join 172.17.0.1:25000/token
and on another machine i did
microk8s join 192.168.0.xxx:25000/token
Contacting cluster at 192.168.0.xxx
Waiting for this node to finish joining the cluster. .. .. .. .. .. .. .. .. .. ..
it ended without messages but on master node command output microk8s.kubectl get no
doesn'show this node only default node
Solution may be as @Sultan Zhumatayev said downgrading microk8s to 1.18
and node will join and appear in node list.
However firstly to check where problem lies you can execute commands: $ microk8s status
and $ microk8s inspect
for a deeper inspection
Another possible solutions:
1. If you turn on firewall (ufw), consider allowing all node ips like: ufw allow from xxx.xxx.xxx.xxx
(repeat for all nodes including the current node). If your instances instances having both an internal and public network, they could try talking to the wrong ones. After taking away the external interfaces, it will work properly. Take a look: microk8s-join-stuck.
2. Try to disconnect the node from the cluster. Run on the node the following command:
$ sudo microk8s leave
Then you can try to connect it again, by running add-node on the master:
$ sudo microk8s add-node
and then the respective command on the node again:
$ sudo microk8s join
Read more: microk8s-join.
See also: microk8s.
I was also having some trouble listing the microk8s nodes and what worked for me was giving an unique hostname of each of the pies in the /etc/hostname
file (the default hostname in all the pies after installation was ubuntu). After I rebooted each of the nodes, they showed up with the microk8s kubectl get no
on the master node.
It seems that microk8s uses the hostname as an identifier for the nodes, or at list the kubectl get node
, instead of their ip, which I would prefer. At least in my case I'm using statics ips in my local network.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With