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

soft "start" without args - will overwrite the container-runtime to docker. #7448

Closed
medyagh opened this issue Apr 6, 2020 · 1 comment · Fixed by #7449
Closed

soft "start" without args - will overwrite the container-runtime to docker. #7448

medyagh opened this issue Apr 6, 2020 · 1 comment · Fixed by #7449

Comments

@medyagh
Copy link
Member

medyagh commented Apr 6, 2020

in this PR I added an integeration test for Soft Start. in TestStartStop.
and it was revealed that our soft start is broken for not-docker runtimes

verified locally

verified locally this happens only when on the Second Start you do NOT specify the run time.

So:

minikube start --driver=hyperkit --container-runtime=conrtainerd
minikube start --driver=hyperkit --container-runtime=conrtainerd

(this one is fine)
but if you do

minikube start 

and in the config, you will see, the run time has been changed to docker

 $ cat ~/.minikube/profiles/minikube/config.json | grep "ContainerRuntime"
                "ContainerRuntime": "docker",

it is not fine !


Test Logs:


it appears that on a restart it generates a WRONG kubeadm config.

-  criSocket: /run/containerd/containerd.sock
+  criSocket: /var/run/dockershim.sock

https://storage.googleapis.com/minikube-builds/logs/7435/0f498bc/KVM_Linux.html#fail_TestStartStop%2fgroup%2fcontainerd

ing, string) (net.Conn, error))(nil)}
	E0406 03:53:37.937401   13793 kubeadm.go:331] Overriding stale ClientConfig host https://192.168.39.96:8444 with https://192.168.39.96:8443
	I0406 03:53:38.063752   13793 ssh_runner.go:101] Run: sudo diff -u /var/tmp/minikube/kubeadm.yaml /var/tmp/minikube/kubeadm.yaml.new
	I0406 03:53:38.118080   13793 kubeadm.go:404] needs reset: configs differ:
	-- stdout --
	--- /var/tmp/minikube/kubeadm.yaml
	+++ /var/tmp/minikube/kubeadm.yaml.new
	@@ -2,7 +2,7 @@
	 kind: InitConfiguration
	 localAPIEndpoint:
	   advertiseAddress: 192.168.39.96
	-  bindPort: 8444
	+  bindPort: 8443
	 bootstrapTokens:
	   - groups:
	       - system:bootstrappers:kubeadm:default-node-token
	@@ -11,7 +11,7 @@
	       - signing
	       - authentication
	 nodeRegistration:
	-  criSocket: /run/containerd/containerd.sock
	+  criSocket: /var/run/dockershim.sock
	   name: "containerd-20200406T034015.056085983-5464"
	   kubeletExtraArgs:
	     node-ip: 192.168.39.96
	@@ -25,7 +25,7 @@
	     enable-admission-plugins: "NamespaceLifecycle,LimitRanger,ServiceAccount,DefaultStorageClass,DefaultTolerationSeconds,NodeRestriction,MutatingAdmissionWebhook,ValidatingAdmissionWebhook,ResourceQuota"
	 certificatesDir: /var/lib/minikube/certs
	 clusterName: mk
	-controlPlaneEndpoint: 192.168.39.96:8444
	+controlPlaneEndpoint: 192.168.39.96:8443
	 dns:
	   type: CoreDNS
	 etcd:
	
	-- /stdout --
	I0406 03:53:38.118207   13793 ssh_run

also in
https://storage.googleapis.com/minikube-builds/logs/7435/0f498bc/KVM_Linux.html#fail_TestStartStop%2fgroup%2fcrio

ing, string) (net.Conn, error))(nil)}
	I0406 03:54:26.658488   14472 ssh_runner.go:101] Run: sudo diff -u /var/tmp/minikube/kubeadm.yaml /var/tmp/minikube/kubeadm.yaml.new
	I0406 03:54:26.715340   14472 kubeadm.go:404] needs reset: configs differ:
	-- stdout --
	--- /var/tmp/minikube/kubeadm.yaml
	+++ /var/tmp/minikube/kubeadm.yaml.new
	@@ -11,7 +11,7 @@
	       - signing
	       - authentication
	 nodeRegistration:
	-  criSocket: /var/run/crio/crio.sock
	+  criSocket: /var/run/dockershim.sock
	   name: "crio-20200406T034015.055332473-5464"
	   kubeletExtraArgs:
	     node-ip: 192.168.39.212
	
	-- /stdout --
	I0406 03:54:26.715449   14472 ssh_runner.go:101] Run: sudo /bin/bash -c "grep https://192.168.39.212:8443 /etc/kubernetes/admin.conf || sudo rm -f /et
@medyagh medyagh changed the title soft restart is broken on non-docker runtimes soft "start" without args - will overwrite the container-runtime to docker. Apr 6, 2020
@afbjorklund
Copy link
Collaborator

Is this the same driver registry bug that makes cri-o look for docker binary ? #5549

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants