mixed balance read and rwordered in read ops#62806
mixed balance read and rwordered in read ops#62806SrinivasaBharath merged 2 commits intoceph:mainfrom
Conversation
5d13b41 to
7e99410
Compare
7e99410 to
7415b79
Compare
|
@athanatos can you please review? |
|
|
||
| // If the op is rwordered, strip out the balanced and localized flags. | ||
| if (flags & CEPH_OSD_FLAG_RWORDERED) { | ||
| ret &= ~(CEPH_OSD_FLAG_BALANCE_READS | CEPH_OSD_FLAG_LOCALIZE_READS); |
| op->rwordered()) { | ||
| dout(4) << __func__ << ": rebalance reads with rwordered not allowed " | ||
| << *m << dendl; | ||
| osd->reply_op_error(op, -EINVAL); |
There was a problem hiding this comment.
As the objecter no longer supports the problematic mixed ops, why are we checking instead of asserting? Is that for the sake of older clients?
There was a problem hiding this comment.
i just wanted to be sure: https://tracker.ceph.com/issues/70715#note-13 see the #2
There was a problem hiding this comment.
Yes, it's for old clients.
You basically have no control over client versions and you need to be ready to handle even misbehaving ones gracefully for long time (this fits particularly well to kernel clients).
Definitely you don't want to assert in such scenario.
|
jenkins test make check |
|
Retriggered make check since the logs expired, but there might be a related issue there. We should check if it happens again. In the meantime, marking this ready for QA since it's been approved. |
src/osd/PrimaryLogPG.cc
Outdated
| CEPH_OSD_FLAG_LOCALIZE_READS)) && | ||
| op->may_read() && | ||
| !(op->may_write() || op->may_cache())) { | ||
| !(op->may_write() || op->may_cache() || op->rwordered())) { |
There was a problem hiding this comment.
IIUC the issue is accepting flag of rwordered and balanced reads - which is handled by:
if (m->has_flag(CEPH_OSD_FLAG_BALANCE_READS) && op->rwordered()) above.
Why are we also adding another check here? This will disallow also localized reads with rwordered, is that the intent?
There was a problem hiding this comment.
There was a problem hiding this comment.
yep, that one is redundant and will add a new issue for localize.
7415b79 to
e18bff7
Compare
Matan-B
left a comment
There was a problem hiding this comment.
LGTM - My comment was addressed - #62806 (review)
'
@rzarzynski, would you like to give this another look as you previously reviewed it? Thanks!
This might need a re-build since the PR has changed.
rzarzynski
left a comment
There was a problem hiding this comment.
I'm afraid we stopped doing the error handling for rwordered, localized reads.
| op->rwordered()) { | ||
| dout(4) << __func__ << ": rebalance reads with rwordered not allowed " | ||
| << *m << dendl; | ||
| osd->reply_op_error(op, -EINVAL); |
There was a problem hiding this comment.
Yes, it's for old clients.
You basically have no control over client versions and you need to be ready to handle even misbehaving ones gracefully for long time (this fits particularly well to kernel clients).
Definitely you don't want to assert in such scenario.
|
jenkins test make check |
|
jenkins test api |
|
@ljflores: the review comments need to be addressed; at the moment merging is blocked. |
e18bff7 to
0a52f39
Compare
|
@rzarzynski please review |
|
Let's put this in a new batch. |
|
|
||
| // If the op is rwordered, strip out the balanced and localized flags. | ||
| if (flags & CEPH_OSD_FLAG_RWORDERED) { | ||
| ret &= ~(CEPH_OSD_FLAG_BALANCE_READS | CEPH_OSD_FLAG_LOCALIZE_READS); |
0a52f39 to
94c4cb4
Compare
|
jenkins test api |
|
jenkins test make check |
Objecter shouldn't sent ops with mixed rwordered and balance_read flags Fixes: https://tracker.ceph.com/issues/70715 Signed-off-by: Nitzan Mordechai <nmordech@redhat.com>
… flags do_op can't accept mixed flag of rwordered and balance_read Fixes: https://tracker.ceph.com/issues/70715 Signed-off-by: Nitzan Mordechai <nmordech@redhat.com>
94c4cb4 to
f68b217
Compare
|
jenkins test make check arm64 |
1 similar comment
|
jenkins test make check arm64 |
…reads This is the counterpart of ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com>
…reads This is the counterpart of ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com>
…reads This is the counterpart of ceph/ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com> (cherry picked from commit 18cfa59bc900460d666c5c686499f87e433cc79f)
…reads This is the counterpart of ceph/ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com> (cherry picked from commit 18cfa59bc900460d666c5c686499f87e433cc79f)
…reads This is the counterpart of ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com>
…reads This is the counterpart of ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com>
…reads This is the counterpart of ceph/ceph#62806 Which fixes classical: https://tracker.ceph.com/issues/70715 Fixes: https://tracker.ceph.com/issues/71007 Signed-off-by: Matan Breizman <mbreizma@redhat.com>
Ops with mixed flags of balance_reads and rwordered will cause errors when send to replica, we should not allow that mix of flags
Fixes: https://tracker.ceph.com/issues/70715
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an
xbetween the brackets:[x]. Spaces and capitalization matter when checking off items this way.Checklist
Show available Jenkins commands
jenkins test classic perfJenkins Job | Jenkins Job Definitionjenkins test crimson perfJenkins Job | Jenkins Job Definitionjenkins test signedJenkins Job | Jenkins Job Definitionjenkins test make checkJenkins Job | Jenkins Job Definitionjenkins test make check arm64Jenkins Job | Jenkins Job Definitionjenkins test submodulesJenkins Job | Jenkins Job Definitionjenkins test dashboardJenkins Job | Jenkins Job Definitionjenkins test dashboard cephadmJenkins Job | Jenkins Job Definitionjenkins test apiJenkins Job | Jenkins Job Definitionjenkins test docsReadTheDocs | Github Workflow Definitionjenkins test ceph-volume allJenkins Jobs | Jenkins Jobs Definitionjenkins test windowsJenkins Job | Jenkins Job Definitionjenkins test rook e2eJenkins Job | Jenkins Job Definition