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

Minikube should log where it gets config options from on start #2053

Closed
jberkus opened this issue Oct 11, 2017 · 8 comments · Fixed by #2078
Closed

Minikube should log where it gets config options from on start #2053

jberkus opened this issue Oct 11, 2017 · 8 comments · Fixed by #2078
Labels
kind/bug Categorizes issue or PR as related to a bug. kind/documentation Categorizes issue or PR as related to documentation.

Comments

@jberkus
Copy link

jberkus commented Oct 11, 2017

BUG REPORT

Please provide the following details:

Environment:

Minikube version : v0.22.3

  • OS : Fedora 25 (Workstation Edition)
  • VM Driver: kvm
  • ISO version: minikube-v0.23.5.iso
  • Install tools:
  • Others:

What happened:

  1. Install KVM dependencies

  2. Fail to configure kvm permissions correctly so that I can run kvm as a non-root user

  3. Attempt to start Minikube using:

minikube start --vm-driver kvm --network-plugin cni
  1. Failed with error:
Error starting host: Error getting state for host: VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path.
  1. Spend 3 hours trying to troubleshoot why --vm-driver is being ignored.

Full error output:

https://paste.fedoraproject.org/paste/UXyu5yBNICuX565Nm-B4Vg

What you expected to happen:

minikube start should have failed with some kind of "could not start kvm" error.

How to reproduce it (as minimally and precisely as possible):

Follow instructions above. An easy way to produce the permissions error is to just not add the user to the libvirtd group.

Output of minikube logs (if applicable):

https://paste.fedoraproject.org/paste/UXyu5yBNICuX565Nm-B4Vg

Anything else do we need to know:

@r2d4 r2d4 added kind/bug Categorizes issue or PR as related to a bug. kind/documentation Categorizes issue or PR as related to documentation. labels Oct 12, 2017
@r2d4
Copy link
Contributor

r2d4 commented Oct 12, 2017

Its not falling back to virtualbox, there just might be some configuration for a machine already started with virtualbox that its reading.

I think a decent fix here would be to just print out the current vm-driver on minikube start so its obvious.

@jberkus
Copy link
Author

jberkus commented Oct 12, 2017

I know that I've never had virtualbox on this machine, but I don't know that there aren't fragments of old .minikube configs in my profile somewhere, so that's possible.

Whether or not we print that on on minikube start normally, it should certainly be visible with -v 9, e.g.

Using vm-driver VirtualBox from /home/josh/.minikube/config

Right now, no matter how much you amp up the logging, the user still has no idea where minikube is getting its configuration info from. This would go for other configuration switches as well.

Should I change the topic of this issue to reflect the actual desired solution?

@r2d4
Copy link
Contributor

r2d4 commented Oct 12, 2017

@jberkus Yeah, that would be great. I'll send a PR shortly to log this info.

@jberkus jberkus changed the title Minikube should not silently fall back on virtualbox if it can't start kvm Minikube should log where it gets config options from on start Oct 12, 2017
@jberkus
Copy link
Author

jberkus commented Oct 12, 2017

Thanks!

@bgehman
Copy link

bgehman commented Oct 15, 2017

I'm pretty sure that minikube will try to use the virtualbox driver if there are any remnants of VirtualBox on the system, regardless of the --vm-driver option passed. Have seen this problem on a couple of developer laptops (they are on macs). See this other bug report for more details: #646 (comment)

CC: @r2d4

@dlorenc
Copy link
Contributor

dlorenc commented Oct 15, 2017

@bgehman It definitely should not be trying to use the virtualbox driver if you've specified another one.

There was an old bug with the xhyve driver though, where it would appear to be trying to use the virtualbox driver if there were any remnants of virtualbox on the system, but that was actually an bug in the xhyve driver. It was trying to check the version of Virtualbox, because some versions of it caused kernel panics when running virtualbox and xhyve simultaneously.

@jberkus
Copy link
Author

jberkus commented Oct 20, 2017

Thanks!

@jberkus
Copy link
Author

jberkus commented Dec 15, 2017

FYI, just had a chance to test this with some local libvirtd issues. MUCH better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. kind/documentation Categorizes issue or PR as related to documentation.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants