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

show docker logs automatically on early error #2016

Closed
AkihiroSuda opened this issue Jan 21, 2021 · 6 comments
Closed

show docker logs automatically on early error #2016

AkihiroSuda opened this issue Jan 21, 2021 · 6 comments
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@AkihiroSuda
Copy link
Member

What would you like to be added:

kind create cluster should run docker logs <CONTAINER> automatically on early error

Why is this needed:
Mostly for showing entrypoint errors to the user.

@AkihiroSuda AkihiroSuda added the kind/feature Categorizes issue or PR as related to a new feature. label Jan 21, 2021
@BenTheElder
Copy link
Member

Hmm:

Errors visible in the node container logs are pretty rare for end users, right now for users wishing to debug the error we point to kind create cluster --retain; kind export logs which captures much more info, generally enough to find the actual root cause.

Unless you're specifically working on kind itself (in which case you probably know how to grab these easily with docker) I'm not sure these are helpful.

Further, dumping lots of logs from e.g. kubeadm to the console has mostly led to users pasting snippets containing "errors" or warnings that are not actually problematic without providing the full context with the real errors, versus asking to upload the full exported logs.

@AkihiroSuda
Copy link
Member Author

Errors visible in the node container logs are pretty rare for end users

Error output introduced in #1935 might be helpful

Further, dumping lots of logs from e.g. kubeadm to the console

docker logs doesn't show so many logs.
Showing kubeadm errors require journalctl.

@BenTheElder
Copy link
Member

Error output introduced in #1935 might be helpful

#1935 is not landed yet, but that may be fair enough then.

docker logs doesn't show so many logs.

nearly all of it is irrelevant though, especially for e.g. multi-node.

Showing kubeadm errors require journalctl.

no, kind invokes kubeadm, not systemd, and when invoking it fails the output is displayed. it's generally not the root cause though.

similarly if container creation fails or containers terminate early, usually the error requires more info than the container logs.

@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

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 21, 2021
@AkihiroSuda
Copy link
Member Author

/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 May 17, 2021
@stmcginnis
Copy link
Contributor

I agree with Ben's assessment above. I don't see it adding a lot of value, and I don't see kind adding this. Should this be closed?

@AkihiroSuda AkihiroSuda closed this as not planned Won't fix, can't repro, duplicate, stale May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

No branches or pull requests

5 participants