microk8s malfunction - can't get pod, can't reset, can't uninstall
Summary
$ sudo snap remove microk8s
error: cannot perform the following tasks:
- Save data of snap "microk8s" in automatic snapshot set #18 (cannot create archive (showing last 5 lines out of 8):
tar: common/default-storage/controller-microk8s-localhost-storage-controller-0-pvc-1e269e55-b062-4357-ab34-925588306091/db: file changed as we read it
tar: common/var/lib/kubelet/pod-resources/kubelet.sock: socket ignored
tar: common/var/lib/kubelet/pods/068e8d8d-4f1a-40f7-a2d4-4a64f1088a84/volumes/kubernetes.io~empty-dir/elasticsearch-logging/nodes/0: file changed as we read it
tar: common/var/lib/kubelet/device-plugins/kubelet.sock: socket ignored
tar: common/run/containerd.sock.ttrpc: socket ignored)
$ sudo microk8s reset
Failed to query the cluster nodes.
WTF is happening?
$ k get pod
Unable to connect to the server: dial tcp 192.168.1.77:16443: connect: no route to host
inspection-report-20230226_135254.tar.gz
What Should Happen Instead?
Reproduction Steps
- ...
- ...
Introspection Report
Can you suggest a fix?
Are you interested in contributing with a fix?
Hi @khteh when you snap remove a snap a snapshot is taken in case you want to retrieve any data at a later point. I think you can skip this snapshot step with the --purge argument in the snap remove command.
From what the error says, I assume there is a process writing data while the snapshot is taken. Could this be the case?
What happen to the error
$ k get pod
Unable to connect to the server: dial tcp 192.168.1.77:16443: connect: no route to host
Did your host change IP?
Maybe. It's DHCP from local router. Why does it matter and how to fix it?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.