-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Log troubleshooting info when console install fails #7132
Log troubleshooting info when console install fails #7132
Conversation
@sdodson Opinion on this change? |
# Ignore errors so we can log troubleshooting info on failures. | ||
ignore_errors: yes | ||
|
||
# Log the reuslt of `oc status`, `oc get pods`, and `oc logs deployment/webconsole` for troubleshooting failures. |
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.
nitpick: comment typo
ignore_errors: true | ||
- debug: | ||
msg: "{{ console_pods.stdout_lines }}" | ||
- name: Get console pod logs |
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.
The pods might not be running if the image cannot be found, could oc get ev
be added to show latest events?
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.
could oc get ev be added to show latest events?
Sure.
Show the results of the following commands for troubleshooting console errors when install fails: * `oc status -n openshift-web-console` * `oc get pods -n openshift-web-console -o wide` * `oc get events -n openshift-web-console * `oc logs deployment/webconsole --tail=50 -n openshift-web-console`
38883bf
to
d0263a5
Compare
@vrutkovs Thanks, updated. |
FWIW, it's possible to see image pull errors even without
I don't think it's bad to list events anyway, though. |
How do we feel about continuing the install/upgrade on failure and then reporting the problem at the end for 'leaf' components where no other components depend on the successful deployment of that component? @ewolinetz @mtnbikenc The stats + callback implementation would facilitate that, would it not? Do we have an example for Sam to reference? |
Yeah, we can use something like the following: - set_stats:
data:
installer_phase_web_console:
message: "The web console failed to install, yadda yadda." |
This is what it looks like with @ewolinetz's suggestion:
|
@sdodson The status code returns 0 when I use |
That's unfortunate, I thought ignore_errors still left the task in a failed state triggering non-zero exit code. @mtnbikenc is this as you'd expect? |
12fda5b
to
1d236e6
Compare
/lgtm |
/lgtm cancel |
1d236e6
to
d0263a5
Compare
@sdodson I added the fail back in per our conversation. |
/lgtm |
/test all [submit-queue is verifying that this PR is safe to merge] |
@sdodson BTW this is a more complete screenshot of what I saw using set_stats instead of fail: |
Automatic merge from submit-queue. |
@spadgett: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. 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. I understand the commands that are listed here. |
Show the results of the following commands for troubleshooting console
errors when install fails:
oc status -n openshift-web-console
oc get pods -n openshift-web-console -o wide
oc get events -n openshift-web-console
oc logs deployment/webconsole --tail=50 -n openshift-web-console
/assign @sdodson
@jwforres FYI