From 6460b61b754143603bba20d86e1d752f6621aa69 Mon Sep 17 00:00:00 2001 From: Yanshu Zhao Date: Wed, 23 Dec 2020 01:48:26 +0000 Subject: [PATCH 1/2] Change exit to warning if can't restart docker in docker-env cmd --- cmd/minikube/cmd/docker-env.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/minikube/cmd/docker-env.go b/cmd/minikube/cmd/docker-env.go index 0f315594b3..9d029ff996 100644 --- a/cmd/minikube/cmd/docker-env.go +++ b/cmd/minikube/cmd/docker-env.go @@ -194,7 +194,8 @@ func mustRestartDockerd(name string, runner command.Runner) { if err := sysinit.New(runner).Reload("docker"); err != nil { klog.Warningf("will try to restart dockerd because reload failed: %v", err) if err := sysinit.New(runner).Restart("docker"); err != nil { - exit.Message(reason.RuntimeRestart, `The Docker service within '{{.name}}' is not active`, out.V{"name": name}) + klog.Warningf("Returning due to %v: The Docker service within '%v' is not active", reason.RuntimeRestart.ID, name) + return } // if we get to the point that we have to restart docker (instead of reload) // will need to wait for apisever container to come up, this usually takes 5 seconds From 68181145bd37c5b60419b4f45e88d97bfe9c6b78 Mon Sep 17 00:00:00 2001 From: Yanshu Zhao Date: Wed, 23 Dec 2020 21:05:43 +0000 Subject: [PATCH 2/2] Add error in the log --- cmd/minikube/cmd/docker-env.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/minikube/cmd/docker-env.go b/cmd/minikube/cmd/docker-env.go index 9d029ff996..3cfced47bc 100644 --- a/cmd/minikube/cmd/docker-env.go +++ b/cmd/minikube/cmd/docker-env.go @@ -194,7 +194,7 @@ func mustRestartDockerd(name string, runner command.Runner) { if err := sysinit.New(runner).Reload("docker"); err != nil { klog.Warningf("will try to restart dockerd because reload failed: %v", err) if err := sysinit.New(runner).Restart("docker"); err != nil { - klog.Warningf("Returning due to %v: The Docker service within '%v' is not active", reason.RuntimeRestart.ID, name) + klog.Warningf("Couldn't restart docker inside minikbue within '%v' because: %v", name, err) return } // if we get to the point that we have to restart docker (instead of reload)