Project

General

Profile

Bug #48076

client: ::_read fails to advance pos at EOF checking

Added by Patrick Donnelly 3 months ago. Updated 12 days ago.

Status:
Resolved
Priority:
Immediate
Category:
-
Target version:
% Done:

0%

Source:
Q/A
Tags:
Backport:
octopus,nautilus
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
Client
Labels (FS):
Pull request ID:
Crash signature:

Description

/ceph/teuthology-archive/pdonnell-2020-11-02_02:29:29-fs:volumes-master-distro-basic-smithi/5581167/teuthology.log

see also

/ceph/teuthology-archive/pdonnell-2020-11-02_02:29:29-fs:volumes-master-distro-basic-smithi/5581167/remote/smithi188/log/ceph-mgr.x.log.gz

2020-11-02T03:32:54.040+0000 7f6572b02700  3 client.6333 read(10, 0x564d4333ec20, 8192, -1) = 0

::_read returns 0 because of

https://github.com/ceph/ceph/blob/161b7e118b4ef5096fac58ceb71eeb905a673b64/src/client/Client.cc#L9557

which prevents f->pos from advancing:

https://github.com/ceph/ceph/blob/161b7e118b4ef5096fac58ceb71eeb905a673b64/src/client/Client.cc#L9571

and then ::read converts the 0 return value to the buffer length:

https://github.com/ceph/ceph/blob/161b7e118b4ef5096fac58ceb71eeb905a673b64/src/client/Client.cc#L9448

The end result is two reads (with offset=-1) that return the same values.


Related issues

Copied to CephFS - Backport #48109: octopus: client: ::_read fails to advance pos at EOF checking Resolved
Copied to CephFS - Backport #48110: nautilus: client: ::_read fails to advance pos at EOF checking Resolved

History

#1 Updated by Patrick Donnelly 3 months ago

  • Status changed from In Progress to Pending Backport
  • Pull request ID set to 37923

#2 Updated by Nathan Cutler 3 months ago

  • Copied to Backport #48109: octopus: client: ::_read fails to advance pos at EOF checking added

#3 Updated by Nathan Cutler 3 months ago

  • Copied to Backport #48110: nautilus: client: ::_read fails to advance pos at EOF checking added

#4 Updated by Nathan Cutler 12 days ago

  • Status changed from Pending Backport to Resolved

While running with --resolve-parent, the script "backport-create-issue" noticed that all backports of this issue are in status "Resolved" or "Rejected".

Also available in: Atom PDF