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

Error setting up kubeconfig: failed to encode config: converting to : type names don't match #1618

Closed
adityardesai opened this issue Jun 20, 2017 · 13 comments
Labels
kind/bug Categorizes issue or PR as related to a bug. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@adityardesai
Copy link

Is this a BUG REPORT or FEATURE REQUEST? (choose one):
BUG REPORT

Minikube version (use minikube version):
minikube version: v0.19.1

Environment:

  • OS (e.g. from /etc/os-release): Mac OS Sierra 10.12.5
  • VM Driver (e.g. cat ~/.minikube/machines/minikube/config.json | grep DriverName):"DriverName": "virtualbox"
  • ISO version (e.g. cat ~/.minikube/machines/minikube/config.json | grep -i ISO or minikube ssh cat /etc/VERSION): "Boot2DockerURL": "file:///Users/addesai/.minikube/cache/iso/minikube-v0.18.0.iso"
  • Install tools:
  • Others:

What happened:
When I run the command minikube start --vm-driver=virtualbox, I see the following error

Error setting up kubeconfig:  could not write to '/Users/adityardesai/.kube/config': failed to encode config: converting  to : type names don't match (Unknown, RawExtension), and no conversion 'func (runtime.Unknown, runtime.RawExtension) error' registered.
================================================================================
An error has occurred. Would you like to opt in to sending anonymized crash
information to minikube to help prevent future errors?
To opt out of these messages, run the command:
	minikube config set WantReportErrorPrompt false
================================================================================
Please enter your response [Y/n]: 

What you expected to happen:
I expect the kubernetes to start working without this error.

How to reproduce it (as minimally and precisely as possible):
Start installing kubernetes from scratch on Mac OS and try to start it

Anything else do we need to know:

@aaron-prindle aaron-prindle added the kind/bug Categorizes issue or PR as related to a bug. label Jun 25, 2017
@darkowlzz
Copy link
Contributor

@adityardesai is this still happening with minikube version: v0.20.0 ?
I am not able to reproduce it.

@hotcoder
Copy link

hotcoder commented Oct 3, 2017

$ minikube start
Starting local Kubernetes v1.7.5 cluster...
Starting VM...

after this nothing is coming

@ColdHeat
Copy link

I have a similar issue.

I deleted ~/.minikube and redownloaded the ISO but still seems stuck.

❯ minikube start --vm-driver=vmwarefusion
Starting local Kubernetes v1.8.0 cluster...
Starting VM...
Downloading Minikube ISO
 140.01 MB / 140.01 MB [============================================] 100.00% 0s

I do not see a VM in the Fusion library either.

@ColdHeat
Copy link

@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

Prevent issues from auto-closing with an /lifecycle frozen comment.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or @fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jan 25, 2018
@fejta-bot
Copy link

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle rotten
/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Feb 24, 2018
@fejta-bot
Copy link

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

@blind3dd
Copy link

blind3dd commented Apr 25, 2018

answered to the post out here (more detailed)
https://superuser.com/questions/1295452/how-to-run-docker-in-virtualbox-mac-os-sierra/1317221#1317221

This is how you solve it:
basically minikube stop and delete $HOME/.minikube content, then kext disable, then firewall privacy change, which is allowing from anywhere click button in system preferences firewall that shall appear, then VirtualBox reinstall process (update/reinstall, if fails don't worry), then
unload and load back again the Virtualbox plugins from "/Library/Application Support/VirtualBox" folder.
Having selected "allow from anywhere" from after kext disable step you'd be able to allow again, but this time it'll be from Oracle America specifically during loading these plugins from VirtualBox folder. Click on it.

Now, you're good to go
minikube start --vm-driver=virtualbox
🥁

@chorwitt
Copy link

I found that simply running "rm -rf $HOME/.minikube" and then running "minikube start --vm-driver=virtualbox" fixed minikube not running for me.

@blind3dd
Copy link

blind3dd commented May 11, 2018

For me obviously, it wouldn’t - spent like half of the day doing a loot of stuff about it the other day - found out that really lot of people have encountered similar issues about that minikube, virtual box or both. All answers would indicate on sth with only part of the issue context in them or sometimes sb would be pointing the security out . It’s worth adding, that Virtualbox driver would actually log that It was well known issue (during minikube start) and that updating to certain version should help / for many it Haven’t.

@zgramana
Copy link

zgramana commented Mar 21, 2019

I had this issue on macOS 10.14 (Mojave) and resolved it by switching to HyperKit (virtualbox is the default) by running the following commands:

rm -Rf ~/.minikube
brew install docker-machine-driver-hyperkit
sudo chown root:wheel /usr/local/opt/docker-machine-driver-hyperkit/bin/docker-machine-driver-hyperkit
sudo chmod u+s /usr/local/opt/docker-machine-driver-hyperkit/bin/docker-machine-driver-hyperkit
minikube start --vm-driver=hyperkit

@tstromberg tstromberg changed the title minikube start --vm-driver=virtualbox is not working on Mac OS Sierra Error setting up kubeconfig: failed to encode config: converting to : type names don't match Mar 22, 2019
@tstromberg
Copy link
Contributor

If you do run into this - look at ~/.kube/config, because something in there is corrupt, or at least not parseable by minikube.

If you want to be destructive:

rm ~/.kube/config && minikube delete

@zgramana
Copy link

I did quite a bit of digging, and it boiled down to Start never actually started and eventually found an error at -v9 saying the OS could not be identified. AFAICT .kube/config looked normal, but that was just by eyeball so I could easily have missed something small (or invisible chars).

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. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

No branches or pull requests