-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Check for cri-dockerd & dockerd runtimes when using none-driver on Kubernetes 1.24+ #14555
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you please put Before/After this PR in the description ?
with one linux system without cri-dockerd installed and another with that installed
also please put output of a none driver with older k8s verison (without cir-dockerd) and it should not exit or warn user
@klaases Please see this comment, |
Yes, taking a look, thanks! |
Hi @medyagh, what is the best way to downgrade k8s version for minikube? I tried installing an older version as well as passing |
After restarting Linux, minikube was able to start with Kubernetes less than v.1.24, and without /ok-to-test |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
Updated before section with the following: Before: Linux system without
Before the error was:
After the error is:
This should make it easier to tell that CRI-DOCKER needs to be installed. |
Thanks @spowelljr for indicating that
However now the before code returns the following error:
TODO: confirm whether the Available() is actually being called. |
please ensure the PR description is correct,
it should be greater or equal to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you please clarify in the PR description if this check happens Before or After minikube tries to install Kubernetes? (I suggest attaching the lastStart log file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like this PR to Proactively return a clean message instead of Failing and letting the failure to go to the RegEx matching
instead of
$ sudo -E ./out/minikube start --driver=none
😄 minikube v1.26.0 on Debian rodete (kvm/amd64)
✨ Using the none driver based on user configuration
👍 Starting control plane node minikube in cluster minikube
🤹 Running on localhost (CPUs=48, Memory=181315MB, Disk=142997MB) ...
ℹ️ OS release is Debian GNU/Linux rodete
❌ Exiting due to RUNTIME_ENABLE: Temporary Error: sudo crictl version: exit status 1
stdout:
stderr:
time="2022-07-15T18:33:39Z" level=fatal msg="unable to determine runtime API version: rpc error: code = Unavailable desc = connection error: desc = \"transport: Error while dialing dial unix /var/run/cri-dockerd.sock: connect: connection refused\""
╭───────────────────────────────────────────────────────────────────────────────────────────╮
│ │
│ 😿 If the above advice does not help, please let us know: │
│ 👉 https://github.com/kubernetes/minikube/issues/new/choose │
│ │
│ Please run `minikube logs --file=logs.txt` and attach logs.txt to the GitHub issue. │
│ │
╰───────────────────────────────────────────────────────────────────────────────────────────╯
it should Exit before it Fails and goes to our already RegEx matching (the solution message is already there) the point of this PR is to prevent it to go further before it fails
it should be something like:
$ sudo -E ./out/minikube start --driver=none
😄 minikube v1.26.0 on Debian rodete (kvm/amd64)
✨ Using the none driver based on user configuration
👍 Starting control plane node minikube in cluster minikube
🤹 Running on localhost (CPUs=48, Memory=181315MB, Disk=142997MB) ...
ℹ️ OS release is Debian GNU/Linux rodete
❌ cri-dockerd is not installed , please install ...using the instruction in this URL ...
to achieve this you can use ErrorTypes simmilar to the ones we have in the OCI package, and when the Error is returned the caller of the function can check if the ErrorType is "NoneDependencyCriDockerd" then prints a clean solution message before it goes and fails
Applied. |
kvm2 driver with docker runtime
Times for minikube start: 58.3s 57.5s 57.3s 55.8s 57.6s Times for minikube ingress: 29.3s 30.3s 30.8s 30.3s 29.3s docker driver with docker runtime |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
kvm2 driver with docker runtime
Times for minikube start: 57.9s 60.1s 57.9s 57.4s 57.3s Times for minikube ingress: 32.3s 31.3s 31.3s 29.3s 29.3s docker driver with docker runtime |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
kvm2 driver with docker runtime
Times for minikube start: 54.8s 56.8s 55.7s 56.6s 56.7s Times for minikube ingress: 25.1s 25.6s 26.6s 30.1s 29.1s docker driver with docker runtime |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
kvm2 driver with docker runtime
Times for minikube (PR 14555) ingress: 25.1s 28.6s 25.6s 30.2s 27.1s Times for minikube (PR 14555) start: 57.4s 57.3s 56.4s 55.8s 58.0s docker driver with docker runtime |
kvm2 driver with docker runtime
Times for minikube ingress: 25.1s 25.6s 29.1s 29.6s 29.2s Times for minikube start: 57.2s 55.7s 56.3s 55.6s 56.4s docker driver with docker runtime |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
Updated messaging per above requests. /ok-to-test |
kvm2 driver with docker runtime
Times for minikube (PR 14555) start: 57.2s 55.7s 56.5s 57.5s 57.3s Times for minikube ingress: 28.6s 28.6s 29.6s 29.1s 25.6s docker driver with docker runtime
Times for minikube start: 26.2s 29.9s 26.4s 29.2s 28.3s Times for minikube (PR 14555) ingress: 22.5s 21.9s 22.0s 22.5s 23.9s docker driver with containerd runtime
Times for minikube start: 35.1s 24.1s 23.0s 23.7s 23.3s Times for minikube ingress: 26.4s 26.4s 25.9s 26.4s 27.4s |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: klaases, spowelljr The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
kvm2 driver with docker runtime
Times for minikube start: 55.0s 57.9s 56.8s 55.6s 53.6s Times for minikube ingress: 30.1s 30.7s 25.0s 29.5s 25.6s docker driver with docker runtime
Times for minikube start: 27.8s 27.3s 28.7s 27.6s 29.1s Times for minikube (PR 14555) ingress: 23.5s 22.9s 23.5s 23.0s 22.5s docker driver with containerd runtime
Times for minikube ingress: 27.0s 27.0s 27.4s 27.4s 27.4s Times for minikube (PR 14555) start: 34.8s 24.5s 24.0s 22.5s 23.8s |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
lets have a better PR tittle for this, the goal is, we should be able to say what the PR is doing in the changelog |
Fixes #14410
Fixes #14460
Check for
cri-dockerd
anddockerd
in addition todocker
, to help the user tell whether they have all the requirements to run the docker container runtime.Checks for both
cri-dockerd
anddockerd
only apply if the Kubernetes version is greater than or equal to v1.24.Run minikube with
none
driver:sudo -E ./out/minikube start --driver=none
If CONNTRACK is missing, install with:
sudo apt-get install -y conntrack
Before: Linux system without
cri-dockerd
installed with k8s >= v.1.24.After: Linux system without
cri-dockerd
installed with k8s >= v.1.24.Next, install
cri-dockerd
, (installation guide).Note: if you encounter the error
crictl
not found:By default,
crictl
will work from/usr/local/bin/
, however minikube requirescrictl
to be in/usr/bin/
(more information).Manually fix
sudo crictl
by running the following command:sudo cp /usr/local/bin/crictl /usr/bin/crictl
After: Linux system with
cri-dockerd
installed with Kubernetes >= 1.24.After: Linux system without
cri-dockerd
installed and with older version of Kubernetes less than 1.24.Uninstall
cri-dockerd
, or make unavailable with:sudo mv cri-dockerd cri-dockerd1
Downgrade Kubernetes (this did not work, need to instead use a minikube flag like
--kubernetes-version=v1.23.0
):curl -LO https://dl.k8s.io/release/v1.23.0/bin/linux/amd64/kubectl
sudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl
kubectl version --client
Client Version: version.Info{Major:"1", Minor:"23" ...
Note: that a profile cannot be used with the
none
driver.Note: downgrading with
--kubernetes-version=v1.23.0
also did not work.Running
minikube delete
andminikube start --kubernetes-version=v1.23.0
work, however even after running minikube with v.1.23,sudo -E ./out/minikube start --driver=none --kubernetes-version=v1.23.0
produces the above error.The solution was to completely restart the Linux system.
Subsequent tests with and without
--force
and both worked as expected.