Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

microk8s does not start after fresh install #4813

Open
mikhatanu opened this issue Jan 7, 2025 · 3 comments
Open

microk8s does not start after fresh install #4813

mikhatanu opened this issue Jan 7, 2025 · 3 comments

Comments

@mikhatanu
Copy link

mikhatanu commented Jan 7, 2025

Summary

microk8s cannot start after fresh install. On a similar vm (same os version (ubuntul 22.04.5 lts), same microk8s version (1.32/stable), same storage size and file system), microk8s can start successfully.

What Should Happen Instead?

microk8s start

Reproduction Steps

  1. sudo snap install microk8s --classic --channel=1.32/stable
  2. microk8s status
    microk8s is not running. Use microk8s inspect for a deeper inspection.
  3. microk8s inspect
Inspecting system
Inspecting Certificates
Inspecting services
  Service snap.microk8s.daemon-cluster-agent is running
  Service snap.microk8s.daemon-containerd is running
  Service snap.microk8s.daemon-kubelite is running
  Service snap.microk8s.daemon-k8s-dqlite is running
  Service snap.microk8s.daemon-apiserver-kicker is running
  Copy service arguments to the final report tarball
Inspecting AppArmor configuration
Gathering system information
  Copy processes list to the final report tarball
  Copy disk usage information to the final report tarball
  Copy memory usage information to the final report tarball
  Copy server uptime to the final report tarball
  Copy openSSL information to the final report tarball
  Copy snap list to the final report tarball
  Copy VM name (or none) to the final report tarball
  Copy current linux distribution to the final report tarball
  Copy asnycio usage and limits to the final report tarball
  Copy inotify max_user_instances and max_user_watches to the final report tarball
  Copy network configuration to the final report tarball
Inspecting kubernetes cluster
  Inspect kubernetes cluster
Inspecting dqlite
  Inspect dqlite
cp: cannot stat '/var/snap/microk8s/7537/var/kubernetes/backend/localnode.yaml': No such file or directory

Building the report tarball
  Report tarball is at /var/snap/microk8s/7537/inspection-report-20250107_155414.tar.gz
  1. Reinstall microk8s
snap remove microk8s --purge
snap install microk8s --classic --channel=1.31/stable
snap refresh microk8s --channel=1.32/stable

Problem still occur

Introspection Report

inspection-report-20250107_161102.tar.gz

Can you suggest a fix?

Are you interested in contributing with a fix?

no

@mikhatanu
Copy link
Author

Fixed after rebooting. I don't know what makes this node needs to be rebooted when similar nodes does not need to be rebooted.

@louiseschmidtgen
Copy link
Contributor

Hi @mikhatanu,

Thank you so much for reporting your issue along-side of the report.

On the first look one error message stands out in the containerd daemon's logs:

Jan 07 15:51:02 app-mendix-beta-dcc microk8s.daemon-containerd[605041]: time="2025-01-07T15:51:02.253696862+07:00" level=error msg="failed to load cni during init, please check CRI plugin status before setting up network for pods" error="cni config load failed: no network config found in /var/snap/microk8s/7537/args/cni-network: cni plugin not initialized: failed to load cni config"

There seems to be a missing CNI config file. If the CNI is not properly initialized it can cause the api-server and other components to fail to start.

Have you been able to reproduce this issue?

@mikhatanu
Copy link
Author

I was installing a microk8s on 2 VM. This happened on the second VM. The first VM installs smoothly. VM is same, with the only different is the IPs. A VM reboot fixed it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants