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 not create profile if driver is not usable #6901

Closed
medyagh opened this issue Mar 5, 2020 · 3 comments
Closed

minikube should not create profile if driver is not usable #6901

medyagh opened this issue Mar 5, 2020 · 3 comments
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. kind/bug Categorizes issue or PR as related to a bug. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.

Comments

@medyagh
Copy link
Member

medyagh commented Mar 5, 2020

Here on windows I tried to start minikbue with virtualbox then it rightfully told me I need to enable somethign in my bios
then I wanted to try a different driver (hyperv)
but minbikube already created an abondoned profiile.

it would be nice to minikube to try to delete the profile if the driver is not useable (like virtualbox is not installed or ...) or for any fatal reason. if this is the first time they create this profile

PS C:\Users\medya\workspsace\minikube> .\out\minikube.exe start --vm-driver=virtualbox
* minikube v1.7.3 on Microsoft Windows 10 Enterprise 10.0.18362 Build 18362
* Using the virtualbox driver based on user configuration
* Downloading VM boot image ...
* Creating virtualbox VM (CPUs=2, Memory=2000MB, Disk=20000MB) ...
* Downloading preloaded images tarball for k8s v1.17.3 ...
    > preloaded-images-k8s-v1-v1.17.3-docker-overlay2.tar.lz4: 137.58 MiB / 499*
X Unable to start VM. Please investigate and run 'minikube delete' if possible
* Error: [VBOX_VTX_DISABLED] creating host: create: precreate: This computer doesn't have VT-X/AMD-v enabled. Enabling it in the BIOS is mandatory
* Suggestion: Virtualization support is disabled on your computer. If you are running minikube within a VM, try '--driver=none'. Otherwise, consult your systems BIOS manual for how to enable virtualization.
* Related issues:
  - https://github.com/kubernetes/minikube/issues/3900
  - https://github.com/kubernetes/minikube/issues/4730
PS C:\Users\medya\workspsace\minikube> .\out\minikube.exe profile list
|----------|------------|---------|----|------|---------|--------|
| Profile  | VM Driver  | Runtime | IP | Port | Version | Status |
|----------|------------|---------|----|------|---------|--------|
| minikube | virtualbox | docker  |    | 8443 | v1.17.3 |        |
|----------|------------|---------|----|------|---------|--------|

@medyagh medyagh added kind/bug Categorizes issue or PR as related to a bug. good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. labels Mar 7, 2020
@loftkun
Copy link
Contributor

loftkun commented Mar 11, 2020

/assign

@loftkun
Copy link
Contributor

loftkun commented Mar 12, 2020

I'll make the following changes:

  1. add the error handlings in startNode() of cmd/minikube/cmd/start.go.
  2. delete profile when failed to startNode().
  // add the error handlings. return err when failed to start.
  kubeconfig, err := startNode(existing, mc, n)
  if err != nil {
+  	  deleteProfile(profile) // delete profile
  	  exit.WithError("Starting node", err)
  }

@loftkun
Copy link
Contributor

loftkun commented Apr 6, 2020

This issue seems to be dealed with in #7345.
can this issue be closed ?

@loftkun loftkun removed their assignment Apr 6, 2020
@medyagh medyagh closed this as completed May 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. kind/bug Categorizes issue or PR as related to a bug. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Projects
None yet
Development

No branches or pull requests

2 participants