sudo yum -y install epel-release
sudo yum -y install libvirt qemu-kvm virt-install virt-top libguestfs-tools bridge-utils
Assuming you can access virsh do the following:
Type virsh
Type net-list --all - should see that minikube-net is inactive
Type net-start minikube-net - should get an error message about "Network is already in use by interface virbr1" or similar
Quit virsh
Type sudo ifconfig virbr1 down
Type sudo brctl delbr virbr1
Type virsh
Type net-start minikube-net - should now start-up
Quit virsh
Type minikube start
$ minikube start
o minikube v0.35.0 on linux (amd64)
> Creating virtualbox VM (CPUs=2, Memory=2048MB, Disk=20000MB) ...
@ Downloading Minikube ISO ...
184.42 MB / 184.42 MB [============================================] 100.00% 0sk
! Unable to start VM: create: precreate: VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path
- Make sure to install all necessary requirements, according to the documentation:
- https://kubernetes.io/docs/tasks/tools/install-minikube/
$ minikube start --vm-driver kvm2
o minikube v0.35.0 on linux (amd64)
- minikube will upgrade the local cluster from Kubernetes 1.13.2 to 1.13.4
! Ignoring --vm-driver=kvm2, as the existing "minikube" VM was created using the none driver.
! To switch drivers, you may create a new VM using `minikube start -p <name> --vm-driver=kvm2`
! Alternatively, you may delete the existing VM using `minikube delete -p minikube`
: Re-using the currently running none VM for "minikube" ...
: Waiting for SSH access ...
- "minikube" IP address is 192.168.213.4
- Configuring Docker as the container runtime ...
- Preparing Kubernetes environment ...
@ Downloading kubeadm v1.13.4
@ Downloading kubelet v1.13.4
- Pulling images required by Kubernetes v1.13.4 ...
: Relaunching Kubernetes v1.13.4 using kubeadm ...
: Waiting for pods: apiserver proxy etcd scheduler controller addon-manager dns
: Updating kube-proxy configuration ...
- Verifying component health .....
+ kubectl is now configured to use "minikube"
= Done! Thank you for using minikube!
$ minikube delete -p minikube
x Deleting "minikube" from none ...
- The "minikube" cluster has been deleted.
$ sudo /usr/local/bin/minikube start --vm-driver=kvm2
o minikube v0.35.0 on linux (amd64)
> Creating kvm2 VM (CPUs=2, Memory=2048MB, Disk=20000MB) ...
@ Downloading Minikube ISO ...
184.42 MB / 184.42 MB [============================================] 100.00% 0s
! Unable to start VM: new host: Driver "kvm2" not found. Do you have the plugin binary "docker-machine-driver-kvm2" accessible in your PATH?
- Make sure to install all necessary requirements, according to the documentation:
- https://kubernetes.io/docs/tasks/tools/install-minikube/
[prabhu@localhost ~]$ sudo su -
Last login: Sat Mar 9 22:11:26 EST 2019 on pts/0
[root@localhost ~]# minikube start --vm-driver=kvm2
o minikube v0.35.0 on linux (amd64)
> Creating kvm2 VM (CPUs=2, Memory=2048MB, Disk=20000MB) ...
! Unable to start VM: create: Error creating machine: Error in driver during machine creation: ensuring active networks: checking network default: virError(Code=43, Domain=19, Message='Network not found: no network with matching name 'default'')
* Sorry that minikube crashed. If this was unexpected, we would love to hear from you:
- https://github.com/kubernetes/minikube/issues/new
After working on this for 3 days, I found that setting up minikube on kvm2 through nested virtualization doesn't work. Though some people have claimed that it works on Fedora but not on CentOS. I was on the verge of giving up but somehow managed to troubleshoot the issues and brought up minikube on kvm2
[root@localhost ~]# minikube start --vm-driver kvm2
o minikube v0.35.0 on linux (amd64)
> Creating kvm2 VM (CPUs=2, Memory=2048MB, Disk=20000MB) ...
- "minikube" IP address is 192.168.39.184
- Configuring Docker as the container runtime ...
- Preparing Kubernetes environment ...
@ Downloading kubeadm v1.13.4
@ Downloading kubelet v1.13.4
- Pulling images required by Kubernetes v1.13.4 ...
- Launching Kubernetes v1.13.4 using kubeadm ...
: Waiting for pods: apiserver proxy etcd scheduler controller addon-manager dns
- Configuring cluster permissions ...
- Verifying component health .....
+ kubectl is now configured to use "minikube"
= Done! Thank you for using minikube!
But i think i have to get an external bootable disk sooner to avoid such issues in future. another big advantage of booting up linux directly is that i can have more resources for kubernetes.
No comments:
Post a Comment