Microk8s leave doesn't finish - v1.21 on RPI4

Three RPI4s running Ubuntu arm64 18.04LTS, server image.
installed microk8s on all 4 and joined them to the cluster without apparent errors.
But I could never see the nodes show up with:
microk8s.kubectl get nodes

I want to redo the deployment and when I go to each node and run ‘microk8s leave’ the command never finishes. Doesn’t return to the prompt, no feedback. Happens on both nodes. I’ve let it run overnight so it doesn’t seem to be just a ‘it’s slow’ thing.

If I quit the command and try to join I get the
Connection failed. The joining node (192.168.xx.yy) is already known to dqlite. (504).

So clearly the leave isn’t processing.



Turns out that the two nodes had this warning when running ‘microk8s inspect’

WARNING: The memory cgroup is not enabled.
The cluster may not be functioning properly. Please ensure cgroups are enabled

Did a snap uninstall of microk8s on all 3 machines, did the cgroup fix on the two RPIs that didn’t have it and now I’ll rebuild the cluster.