Bug 107015
| Summary: | aio_return wrongly yields zero | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 2.1 | Reporter: | Yngve Svendsen <yngve.svendsen> |
| Component: | glibc | Assignee: | Jakub Jelinek <jakub> |
| Status: | CLOSED WORKSFORME | QA Contact: | Brian Brock <bbrock> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 2.1 | CC: | alexey, bruce.grove, fweimer, tao |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | i686 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2004-08-26 05:07:47 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
are you using glibc or kernel AIO ? It comes from /usr/include/aio.h, so that would make it part of glibc as far as we can see. then the kernel is the wrong component to file this against ;) Is there any progress on this? We have seen instances where the workaround of calling aio_return once more does not help. Calling it yet again seems to "always" generate the correct answer, since the chance of the bug occuring a third time in one go is so small. I haven't been able to reproduce this. Can you provide a testcase? No answer in 7 months. Closing. It seems that the fix for bug #132494 (for RHEL 3AS) should be backported to 2.1AS. Should it? |
Description of problem: From one of our developers: There seems to be a bug in asynchronous I/O on this platform. We schedule an I/O operation, read or write, and wait for completion notification. We then call aio_error(), and if this call returns zero, we call aio_return(). In roughly one out of 1.000.000 calls, aio_return() will reply with zero, rather than 16K, the size of our I/O request. This of course, makes our database server fail. When forcing a core-dump in this situation, I could see that the aiocb struct contained the value 16K, even though aio_return() had returned zero. As an ad hoc workaround, I called aio_return() one more time, after having printed a warning, it then returns 16K (!!!!) According to the specificaion, aio_return() should be called exactly once. We disassembled the routine, it simply returns a value in the aiocb struct, so calling it twice should be OK. To me, this seems to a thread/process synchronization bug in asynch I/O on this platform. Version-Release number of selected component (if applicable): QU2 kernel (2.4.9-e.24) and unofficial e.27.6 How reproducible: Approx 1/1 million Steps to Reproduce: 1. Schedule IO, wait for completion 2. Call aio_error 3. if aio_error returns zero, call aio_return Actual results: aio_return yields 0 K Expected results: aio_return should yield 16 K Additional info: This will be flagged in the Sun - Redhat Issue Tracker