Bug 152002
Summary: | RHEL4 Write system call returns succes on partial writes | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 4 | Reporter: | Marty Wesley <mwesley> |
Component: | kernel | Assignee: | Eric Sandeen <esandeen> |
Status: | CLOSED NOTABUG | QA Contact: | Brian Brock <bbrock> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 4.0 | CC: | coughlan, jbaron, riel, staubach, tao |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2007-08-29 15:34:02 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: |
Description
Marty Wesley
2005-03-24 05:10:39 UTC
> This is the RHEL4 version of bugzilla 116900.
I don't see anything in bugzilla 116900 that says it will occur in RHEL 4. Maybe
that should be tested though.
Stephen, I'll assign this to you, since you own 116900. Assign it back to me if
it is something I should handle.
> The RedHat support team has recreated this problem using a simpler
> user mode write test case combining with a kernel scsi error injection
> debug patch
Hmmmm 2.5 years later I don't suppose that patch is still around anywhere..? :)
This is actually expected. Well, intended. Perhaps not expected. :) If we look in generic_file_buffered_write() in mm/filemap.c: /* * For now, when the user asks for O_SYNC, we'll actually give O_DSYNC */ if (likely(status >= 0)) { if (unlikely((file->f_flags & O_SYNC) || IS_SYNC(inode))) { if (!a_ops->writepage || !is_sync_kiocb(iocb)) status = generic_osync_inode(inode, mapping, OSYNC_METADATA|OSYNC_DATA); } } "For now" extents to current kernels as well, FWIW. Also those 2 flags, OSYNC_METADATA|OSYNC_DATA, do *not* sync the inode. So the inode gets written out only in writeback, long after the application has returned. Although I'm not really fond of it, and I'm not sure of the historical reasons for it, I'm tempted to mark this NOTABUG because it's actually working as designed... -Eric Oh, and for what it's worth, the data write itself probably *was* successful, but your inode writeout was not. I almost hate to do this, but because this is how Linux has been - intentionally, it seems - for at least 5 or 6 years, I'm going to close this as NOTABUG, because things are in fact working as designed and as intended. -Eric |