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
src/ceph-crash.in: various enhancements and fixes #42055
Conversation
stdout was never used so let's remove it. Signed-off-by: Sébastien Han <seb@redhat.com>
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.
Other than nits, lgtm
@@ -51,7 +51,7 @@ def post_crash(path): | |||
stderr = pr.communicate(input=f.read()) | |||
rc = pr.wait() | |||
f.close() | |||
if rc != 0: | |||
if rc != 0 or stderr != "": |
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.
just printing to stderr isn't an error, of course, so I don't know that calling this "failed" is really right, but it's a nit
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.
Agreed, but as explained in 8a89e01, I feel like it's better than nothing.
frame was unused so let's remove it. Signed-off-by: Sébastien Han <seb@redhat.com>
Previously when the --name was used, the code will still go through the initial list. Now if --name is passed, only this user will be used to upload crashes. Signed-off-by: Sébastien Han <seb@redhat.com>
Now, the script can run with --log-level DEBUG to enable DEBUG level logging. Signed-off-by: Sébastien Han <seb@redhat.com>
This is not perfect, but we have seen cases where the CLI returns 0 even on failure. For instance: ```sh [root@rook-ceph-crashcollector-compute-1-66bdfbd886-d2zcd /]# ceph -n client.crash crash post -i /var/lib/ceph/crash/2021-06-28T07\:47\:37.859766Z_6ffb119c-930e-4047-9cfa-a92af783cdd0/meta malformed crash metadata: time data '2021-06-28T07:47:37.859766' does not match format '%Y-%m-%d %H:%M:%S.%f' [root@rook-ceph-crashcollector-compute-1-66bdfbd886-d2zcd /]# echo $? 0 ``` So until we find the root cause, let's mitigate and perhaps accomodate for futur similar issues. Signed-off-by: Sébastien Han <seb@redhat.com>
8a89e01
to
a77b47e
Compare
jenkins test make check |
src/ceph-crash.in: various enhancements and fixes
See individual commits.
Checklist
Show available Jenkins commands
jenkins retest this please
jenkins test classic perf
jenkins test crimson perf
jenkins test signed
jenkins test make check
jenkins test make check arm64
jenkins test submodules
jenkins test dashboard
jenkins test api
jenkins test docs
jenkins render docs
jenkins test ceph-volume all
jenkins test ceph-volume tox