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

minikube checks for updates from the releases-v2.json file every time it starts. #19735

Open
nirajanpdl opened this issue Sep 30, 2024 · 4 comments
Assignees
Labels
kind/regression Categorizes issue or PR as related to a regression from a prior release.

Comments

@nirajanpdl
Copy link

What Happened?

In air gapped environment minikube is looking for releases-v2.json file "https://storage.googleapis.com/minikube/releases-v2.json": everry time we start minikube.

This issue is seen from minikube v1.33.0. how to fix it in air gapped environment ?

Attach the log file

Running on machine: host
Binary: Built with gc go1.22.5 for linux/amd64
Log line format: [IWEF]mmdd hh:mm:ss.uuuuuu threadid file:line] msg
I0930 15:57:55.260968 1341420 out.go:345] Setting OutFile to fd 1 ...
I0930 15:57:55.261474 1341420 out.go:392] TERM=xterm,COLORTERM=, which probably does not support color
I0930 15:57:55.261478 1341420 out.go:358] Setting ErrFile to fd 2...
I0930 15:57:55.261483 1341420 out.go:392] TERM=xterm,COLORTERM=, which probably does not support color
I0930 15:57:55.261670 1341420 root.go:338] Updating PATH: /home/user/.minikube/bin
I0930 15:57:55.262075 1341420 out.go:352] Setting JSON to false
I0930 15:57:55.263823 1341420 start.go:129] hostinfo: {"hostname":"host-22-1-4-79","uptime":24780,"bootTime":1727667296,"procs":325,"os":"linux","platform":"ubuntu","platformFamily":"debian","platformVersion":"22.04","kernelVersion":"5.15.0-102-generic","kernelArch":"x86_64","virtualizationSystem":"kvm","virtualizationRole":"guest","hostId":"a63cc7ec-7f02-4eb4-a18a-4529f6bd13fa"}
I0930 15:57:55.263894 1341420 start.go:139] virtualization: kvm guest
I0930 15:57:55.265418 1341420 out.go:177] * minikube v1.34.0 on Ubuntu 22.04 (kvm/amd64)
I0930 15:57:55.266084 1341420 notify.go:220] Checking for updates...
I0930 15:57:55.266102 1341420 out.go:177] - MINIKUBE_WANTREPORTERRORPROMPT=false
W0930 15:57:55.266079 1341420 preload.go:293] Failed to list preload files: open /home/user/.minikube/cache/preloaded-tarball: no such file or directory
I0930 15:57:55.266815 1341420 out.go:177] - KUBECONFIG=/home/user/.kube/config
I0930 15:57:55.267402 1341420 out.go:177] - MINIKUBE_HOME=/home/user
I0930 15:57:55.267949 1341420 out.go:177] - MINIKUBE_WANTUPDATENOTIFICATION=false
W0930 15:57:55.268665 1341420 out.go:270] ! Specified Kubernetes version 1.31.1 is newer than the newest supported version: v1.31.0. Use minikube config defaults kubernetes-version for details.
W0930 15:57:55.268699 1341420 out.go:270] ! Specified Kubernetes version 1.31.1 not found in Kubernetes version list
I0930 15:57:55.269261 1341420 out.go:177] * Searching the internet for Kubernetes version...
W0930 15:57:55.273332 1341420 notify.go:59] Error getting json from minikube version url: error with http GET for endpoint https://storage.googleapis.com/minikube/releases-v2.json: Get "https://storage.googleapis.com/minikube/releases-v2.json": dial tcp 127.0.0.1:443: connect: connection refused
I0930 15:58:25.271440 1341420 out.go:201]
W0930 15:58:25.272459 1341420 out.go:270] X Exiting due to K8S_FAIL_CONNECT: error fetching Kubernetes version list from GitHub: Get "https://github.com/repos/kubernetes/kubernetes/releases/tags/v1.31.1": dial tcp 140.82.121.6:443: i/o timeout
W0930 15:58:25.272495 1341420 out.go:270] *
W0930 15:58:25.273648 1341420 out.go:293] ╭─────────────────────────────────────────────────────────────────────────────────────────────╮
│ │
│ * 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. │
│ │

Operating System

Ubuntu

Driver

None

@spowelljr
Copy link
Member

Hi @nirajanpdl, you should be able to run minikube config set WantUpdateNotification false, however, the logic is incorrectly doing the curl command before checking the config value, so in the current state it will still attempt to make a call, I'll make a PR to correct this.

@spowelljr spowelljr self-assigned this Sep 30, 2024
@spowelljr spowelljr added the kind/bug Categorizes issue or PR as related to a bug. label Sep 30, 2024
@spowelljr
Copy link
Member

Just following up, the call to the releases file is not what's causing your start to fail, it's trying to pull the Kubernetes version list from GitHub is the issue that's causing your start to fail. You should be able to resolve this by using Kubernetes v1.31.0 instead of Kubernetes v1.31.1 and that version wasn't out when we did our last release. Also, have you been following our offline docs? You'll need to have an internet connection at some point to download dependencies, please see: https://minikube.sigs.k8s.io/docs/handbook/offline/

@spowelljr spowelljr added kind/support Categorizes issue or PR as a support question. and removed kind/bug Categorizes issue or PR as related to a bug. labels Oct 2, 2024
@nirajanpdl
Copy link
Author

nirajanpdl commented Oct 3, 2024

Yes with kubernetes version 1.31.0, we are not facing any issue since minikube v1.34.0 defaults to k8s 1.31.0. But, Our requirement is to use kubernetes version 1.31.1. in air gapped environment.

I observed that when using non default kubernetes version, minikube startup is failing starting from minikube v1.33.0.

Note: when I use minikube v1.31.2 on k8s 1.31.1 it works perfectly in air gapped environment. So the issue is seen after v1.33.0.

@spowelljr
Copy link
Member

Some Kubernetes version validation that was added is what you're hitting, this should be resolved for offline usage, but in the meantime adding --force to your start command should prevent this validation from failing your start.

@spowelljr spowelljr added kind/regression Categorizes issue or PR as related to a regression from a prior release. and removed kind/support Categorizes issue or PR as a support question. labels Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/regression Categorizes issue or PR as related to a regression from a prior release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants