From: Goldwyn Rodrigues <rgoldwyn@suse.de>
To: NeilBrown <neilb@suse.com>,
lsf-pc@lists.linux-foundation.org,
Linux FS-devel Mailing List <linux-fsdevel@vger.kernel.org>,
linux-mm@kvack.org
Subject: Re: [LSF/MM ATTEND] memory allocation scope
Date: Thu, 15 Feb 2018 08:19:16 -0600 [thread overview]
Message-ID: <a6dfc5fe-56c5-731e-701b-93cd41cf547b@suse.de> (raw)
In-Reply-To: <87po56q578.fsf@notabene.neil.brown.name>
On 02/14/2018 09:53 PM, NeilBrown wrote:
> On Wed, Feb 14 2018, Goldwyn Rodrigues wrote:
>
>> Discussion with the memory folks towards scope based allocation
>> I am working on converting some of the GFP_NOFS memory allocation calls
>> to new scope API [1]. While other allocation types (noio, nofs,
>> noreclaim) are covered. Are there plans for identifying scope of
>> GFP_ATOMIC allocations? This should cover most (if not all) of the
>> allocation scope.
>>
>> Transient Errors with direct I/O
>> In a large enough direct I/O, bios are split. If any of these bios get
>> an error, the whole I/O is marked as erroneous. What this means at the
>> application level is that part of your direct I/O data may be written
>> while part may not be. In the end, you can have an inconsistent write
>> with some parts of it written and some not. Currently the applications
>> need to overwrite the whole write() again.
>
> So?
> If that is a problem for the application, maybe it should use smaller
> writes. If smaller writes cause higher latency, then use aio to submit
> them.
>
> I doubt that splitting bios is the only thing that can cause a write
> that reported as EIO to have partially completed. An application should
> *always* assume that EIO from a write means that the data on the device
> is indistinguishable from garbage - shouldn't it?
>
Yes, and that is what I got from others as well. The scenario is not
deterministic of the contents of the file in case of overwriting a file.
And no, splitting bios is not the only reason you can have partial
write. This is different from what buffered I/O would result in, where a
partial write may not be an error and returns the bytes written.
Perhaps this needs to be documented in the man pages. I will put in one
shortly.
--
Goldwyn
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2018-02-15 14:19 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-14 22:51 [LSF/MM ATTEND] memory allocation scope Goldwyn Rodrigues
2018-02-15 3:53 ` NeilBrown
2018-02-15 14:19 ` Goldwyn Rodrigues [this message]
2018-02-15 14:48 ` Michal Hocko
2018-02-15 15:57 ` [Lsf-pc] " James Bottomley
2018-02-15 16:02 ` Michal Hocko
2018-02-15 16:06 ` Michal Hocko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a6dfc5fe-56c5-731e-701b-93cd41cf547b@suse.de \
--to=rgoldwyn@suse.de \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lsf-pc@lists.linux-foundation.org \
--cc=neilb@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).