Bug 1288143
Summary: | tuna thows an exception instead of an error message when sched_setaffinity returns EINVAL | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Guy Streeter <streeter> | ||||||
Component: | tuna | Assignee: | John Kacur <jkacur> | ||||||
Status: | CLOSED ERRATA | QA Contact: | Jiri Kastner <jkastner> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | medium | ||||||||
Version: | 6.5 | CC: | bhu, dvacek, jkastner, jshortt, kzhang, nobody | ||||||
Target Milestone: | rc | ||||||||
Target Release: | --- | ||||||||
Hardware: | All | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | |||||||||
: | 1290445 (view as bug list) | Environment: | |||||||
Last Closed: | 2016-05-10 20:53:53 UTC | Type: | Bug | ||||||
Regression: | --- | Mount Type: | --- | ||||||
Documentation: | --- | CRM: | |||||||
Verified Versions: | Category: | --- | |||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||
Embargoed: | |||||||||
Bug Depends On: | |||||||||
Bug Blocks: | 1270066, 1290445 | ||||||||
Attachments: |
|
I've tested this and it works, but will wait for upstream comments before using it for a build I think a slightly more detailed error message would be good. Mention the affected thread by name and/or PID, since the command may have tried to move more than one thread. And, "thread cannot be moved as requested" is clearer than "cannot move thread" for this condition. --Guy I mostly agree, although, "thread cannot be moved as requested", is not clearer because it sounds like it could be moved if you requested it differently. Wordier is not always clearer, it leaves room for more arguments. Anyway, I think this discussion belongs on the tuna mailing list and not on the bugzilla. But we don't know from the error whether requesting it differently would have succeeded. How about "failed to move thread"? How about, "Cannot move unmovable thread (%pid)" You can get EINVAL when a thread is movable, but not as requested. You can also get EINVAL when the thread is unmovable. I think "do not move" or "failed to move" is better. Good point. Going back to your original suggestion, how about the following? # tuna --cpus=1 --threads="migration/*" --move thread 11 cannot be moved as requested thread 28 cannot be moved as requested thread 21 cannot be moved as requested -------------------------- Note that it is simple to get the pid, but the thread name is a bit trickier, so I suggest we leave that as a feature for the future. That looks good to me. Created attachment 1106091 [details]
proposed fix
Fixed in tuna-0.12-2.el6 and up Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2016-0807.html |
Created attachment 1104366 [details] proposed fix