Skip to content

service command executes wrong helper #19878

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

Open
bigon opened this issue Oct 29, 2024 · 13 comments · May be fixed by #20863
Open

service command executes wrong helper #19878

bigon opened this issue Oct 29, 2024 · 13 comments · May be fixed by #20863

Comments

@bigon
Copy link

bigon commented Oct 29, 2024

What Happened?

As you can see bellow, minikube tries to execute kvm2, but this seems wrong.

The driver is called docker-machine-driver-kvm2 (and not in the PATH)

Running debian unstable

$ minikube service --all
|-----------|------------|-------------|--------------|
| NAMESPACE |    NAME    | TARGET PORT |     URL      |
|-----------|------------|-------------|--------------|
| default   | kubernetes |             | No node port |
|-----------|------------|-------------|--------------|
😿  service default/kubernetes has no node port
❗  Services [default/kubernetes] have type "ClusterIP" not meant to be exposed, however for local development minikube allows you to access this !
E1029 14:47:25.572916   77507 out.go:502] unable to execute error getting ssh port: get port 22 for "minikube": kvm2 container inspect -f "'{{(index (index .NetworkSettings.Ports "22/tcp") 0).HostPort}}'" minikube: exec: "kvm2": executable file not found in $PATH
stdout:

stderr:
: template: error getting ssh port: get port 22 for "minikube": kvm2 container inspect -f "'{{(index (index .NetworkSettings.Ports "22/tcp") 0).HostPort}}'" minikube: exec: "kvm2": executable file not found in $PATH
stdout:

stderr:
:1:90: executing "error getting ssh port: get port 22 for \"minikube\": kvm2 container inspect -f \"'{{(index (index .NetworkSettings.Ports \"22/tcp\") 0).HostPort}}'\" minikube: exec: \"kvm2\": executable file not found in $PATH\nstdout:\n\nstderr:\n" at <index .NetworkSettings.Ports "22/tcp">: error calling index: index of untyped nil - returning raw string.

❌  Exiting due to DRV_PORT_FORWARD: error getting ssh port: get port 22 for "minikube": kvm2 container inspect -f "'{{(index (index .NetworkSettings.Ports "22/tcp") 0).HostPort}}'" minikube: exec: "kvm2": executable file not found in $PATH
stdout:

stderr:


╭───────────────────────────────────────────────────────────────────────────────────────────╮
│                                                                                           │
│    😿  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.    │
│    Please also attach the following file to the GitHub issue:                             │
│    - /tmp/minikube_service_7307d14e4bcde4344d1f5773b0e0f52f3b39b30f_0.log                 │
│                                                                                           │
╰───────────────────────────────────────────────────────────────────────────────────────────╯

Attach the log file

minikube_service_7307d14e4bcde4344d1f5773b0e0f52f3b39b30f_0.log

Operating System

Other

Driver

KVM2

@bigon
Copy link
Author

bigon commented Oct 29, 2024

logs.txt

@bigon
Copy link
Author

bigon commented Oct 29, 2024

BTW I find an other similar bugs #18825

@medyagh
Copy link
Member

medyagh commented Oct 30, 2024

@prezha do you mind taking a look?

@medyagh
Copy link
Member

medyagh commented Oct 30, 2024

@bigon do you have multiple profiles ? do you mind sharing
"minikube profile list"

@bigon
Copy link
Author

bigon commented Oct 30, 2024

Hello,

No only one profile

$ minikube profile list
|----------|-----------|---------|----------------|------|---------|---------|-------|----------------|--------------------|
| Profile  | VM Driver | Runtime |       IP       | Port | Version | Status  | Nodes | Active Profile | Active Kubecontext |
|----------|-----------|---------|----------------|------|---------|---------|-------|----------------|--------------------|
| minikube | kvm2      | docker  | 192.168.39.211 | 8443 | v1.31.0 | Running |     1 | *              | *                  |
|----------|-----------|---------|----------------|------|---------|---------|-------|----------------|--------------------|

@prezha
Copy link
Contributor

prezha commented Oct 30, 2024

looks like the problem is that we're always calling the kic-based logic (specifically, the startKicServiceTunnel() func) without checking first if a kic driver is used for given profile, and in this and the other #18825 case, users are using vm/kvm driver, so it fails

the code segment that's making a call without checking (introduced in pr #17877 on 3rd of april this year):
https://github.com/kubernetes/minikube/pull/17877/files#diff-72b0db9f1698ff6131feb23cdcc885688b228eddf388bf36db516dd6e0ede9a8R172-R174

@Ritikaa96
Copy link

Hi @bigon given the above statement this issue should be resolved. can you confirm?

@bigon
Copy link
Author

bigon commented Dec 11, 2024

Hello,

Well according to my understanding, the problem is not fixed

@bigon
Copy link
Author

bigon commented Jan 16, 2025

Hello,

The problem still exists in 1.35.0

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle stale
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 16, 2025
@bigon
Copy link
Author

bigon commented Apr 24, 2025

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 24, 2025
@bigon
Copy link
Author

bigon commented May 23, 2025

Still present in 1.36.0

@prezha prezha linked a pull request May 31, 2025 that will close this issue
@prezha
Copy link
Contributor

prezha commented Jun 1, 2025

@bigon, thanks for opening this issue and for your patience

if you want to try out the fix, please download the binaries from here and let us know if it works for you

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.

6 participants