Minikube: kvm2: 'Failed to connect socket to '/var/run/libvirt/libvirt-sock': Permission denied

Created on 2 Feb 2020  路  8Comments  路  Source: kubernetes/minikube

The exact command to reproduce the issue:

The full output of the command that failed:

The output of the minikube logs command:

The operating system version:

ckvm2 kinsupport triagneeds-information

Most helpful comment

I had the same issue after just installing kvm. I think the KVM module (running for my user) did not have permission to the libvirt-sock which caused the error even though my user should have the correct permission. Since it was a fresh install my user group was added but for that to take effect you have to log out and log back in. Once I did that everything worked fine.

All 8 comments

Do you mind adding some additional details? Here is additional information that would be helpful:

  • The exact minikube start command line used
  • The full output of the minikube start command, preferably with --alsologtostderr -v=1 for extra logging.

Thank you for sharing your experience!

I had the same issue after just installing kvm. I think the KVM module (running for my user) did not have permission to the libvirt-sock which caused the error even though my user should have the correct permission. Since it was a fresh install my user group was added but for that to take effect you have to log out and log back in. Once I did that everything worked fine.

Had the same problem that @LasseJacobs mentioned in a recent installation. I added my user to the libvirt group in ubuntu, but it only took effect after log out/log in.

Maybe we can do a check for this in minikube. :thinking:

There seems to be a solution here, so I'm going to go ahead and close this issue for now. Feel free to reopen if you need any more assistance.

Logging out/in didn't fix it for me on Ubuntu 19.10. However, it worked after a reboot.

Logging out/in works for me!

Faced the same issue with recent installation. Logging out/in didn't fix it for me on Ubuntu 18.04. However, it worked after a reboot.

Had the same issue on Ubuntu 20.04, log out/log in did not work had to reboot my vm.

Was this page helpful?
0 / 5 - 0 ratings