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 profile list --output json fails with ENONT after fresh install #15593

Closed
nirs opened this issue Jan 4, 2023 · 10 comments · Fixed by #16900
Closed

minikube profile list --output json fails with ENONT after fresh install #15593

nirs opened this issue Jan 4, 2023 · 10 comments · Fixed by #16900
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@nirs
Copy link
Contributor

nirs commented Jan 4, 2023

What Happened?

After minikube on a fresh machine, running:

minikube profile list --output json

Fails, writing error to stdout:

{"error":{"Op":"open","Path":"/home/runner/.minikube/profiles","Err":2}}

The expected output:

{"invalid":[],"valid":[]}

Issues:

  • Missing ~/.minikube/profiles not handled gracefully
  • Reporting errors to stdout
  • Reporting error number (2) instead of description (No such file or directory).

Workaround:

  • Create .minikube/profiles manually before running the command

Attach the log file

Full reproducer:

Add this github workflow:

name: CI
on:
  - push
  - pull_request
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - name: Reproduce minikube bug
        run: |
          curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
          sudo install minikube-linux-amd64 /usr/local/bin/minikube
          minikube --alsologtostderr --v=7 profile list --output json

Example run:

I0104 21:22:57.498168    1632 out.go:296] Setting OutFile to fd 1 ...
I0104 21:22:57.498301    1632 out.go:343] TERM=,COLORTERM=, which probably does not support color
I0104 21:22:57.498306    1632 out.go:309] Setting ErrFile to fd 2...
I0104 21:22:57.498311    1632 out.go:343] TERM=,COLORTERM=, which probably does not support color
I0104 21:22:57.503171    1632 root.go:334] Updating PATH: /home/runner/.minikube/bin
W0104 21:22:57.503308    1632 root.go:311] Error reading config file at /home/runner/.minikube/config/config.json: open /home/runner/.minikube/config/config.json: no such file or directory
I0104 21:22:57.503638    1632 out.go:303] Setting JSON to true
I0104 21:22:57.503749    1632 notify.go:220] Checking for updates...
{"error":{"Op":"open","Path":"/home/runner/.minikube/profiles","Err":2}}

Can also be reproduced by removing (an empty) ~/.minikube/profiles directory.

Operating System

Ubuntu

Driver

N/A

@nirs
Copy link
Contributor Author

nirs commented Jan 4, 2023

The same issue #5898 was reported and fixed #5955 in 2019.

nirs added a commit to nirs/minikube that referenced this issue Jan 4, 2023
This was reported in kubernetes#5898 and fixed in kubernetes#5955 in 2019. However the fix
assumed that `listProfiles()` can return `config.ErrNotExists` while it
returns `os.ErrNotExist` from `os.ReadDir`.

Fixes kubernetes#15593
@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 4, 2023
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active 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 rotten
  • Close this issue with /close
  • Offer to help out with Issue Triage

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

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels May 5, 2023
@nirs
Copy link
Contributor Author

nirs commented May 5, 2023

/remove-lifecycle rotten

@k8s-ci-robot k8s-ci-robot removed the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label May 5, 2023
@nirs
Copy link
Contributor Author

nirs commented May 5, 2023

This issue is addressed by #15594.

nirs added a commit to nirs/ramen that referenced this issue Nov 15, 2023
If `minikube profile list` is called before `minikube start` it fails
because `$MINIKUBE_HOME/.minikube/profiles` does not exist[1]. I posted
a fix[1] on Jan 5 2023 but it was not accepted. Talur posted another
fix[2] on July 18 2023 but it is still waiting for review.

Fixing it in drenv until minikube maintainers find time to handle this.

[1] kubernetes/minikube#15593
[2] kubernetes/minikube#15594
[3] kubernetes/minikube#16900

Signed-off-by: Nir Soffer <[email protected]>
nirs added a commit to nirs/ramen that referenced this issue Nov 15, 2023
If `minikube profile list` is called before `minikube start` it fails
because `$MINIKUBE_HOME/.minikube/profiles` does not exist[1]. I posted
a fix[1] on Jan 5 2023 but it was not accepted. Talur posted another
fix[2] on July 18 2023 but it is still waiting for review.

Fixing it in drenv until minikube maintainers find time to handle this.

[1] kubernetes/minikube#15593
[2] kubernetes/minikube#15594
[3] kubernetes/minikube#16900

Signed-off-by: Nir Soffer <[email protected]>
ShyamsundarR pushed a commit to RamenDR/ramen that referenced this issue Dec 11, 2023
If `minikube profile list` is called before `minikube start` it fails
because `$MINIKUBE_HOME/.minikube/profiles` does not exist[1]. I posted
a fix[1] on Jan 5 2023 but it was not accepted. Talur posted another
fix[2] on July 18 2023 but it is still waiting for review.

Fixing it in drenv until minikube maintainers find time to handle this.

[1] kubernetes/minikube#15593
[2] kubernetes/minikube#15594
[3] kubernetes/minikube#16900

Signed-off-by: Nir Soffer <[email protected]>
ShyamsundarR pushed a commit to red-hat-storage/ramen that referenced this issue Dec 13, 2023
If `minikube profile list` is called before `minikube start` it fails
because `$MINIKUBE_HOME/.minikube/profiles` does not exist[1]. I posted
a fix[1] on Jan 5 2023 but it was not accepted. Talur posted another
fix[2] on July 18 2023 but it is still waiting for review.

Fixing it in drenv until minikube maintainers find time to handle this.

[1] kubernetes/minikube#15593
[2] kubernetes/minikube#15594
[3] kubernetes/minikube#16900

Signed-off-by: Nir Soffer <[email protected]>
@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 Jan 19, 2024
@nirs
Copy link
Contributor Author

nirs commented Jan 19, 2024

/remove-lifecycle rotten

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active 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 rotten
  • Close this issue with /close
  • Offer to help out with Issue Triage

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

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Feb 18, 2024
@k8s-triage-robot
Copy link

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

This bot triages 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:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

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

/close not-planned

@k8s-ci-robot
Copy link
Contributor

@k8s-triage-robot: Closing this issue, marking it as "Not Planned".

In response to this:

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

This bot triages 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:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

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

/close not-planned

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot closed this as not planned Won't fix, can't repro, duplicate, stale Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
3 participants