From mboxrd@z Thu Jan 1 00:00:00 1970 From: jim owens Subject: Re: [rfc] fsync_range? Date: Wed, 21 Jan 2009 16:23:58 -0500 Message-ID: <4977926E.30703@hp.com> References: <20090120183120.GD27464@shareable.org> <20090121012900.GD24891@wotan.suse.de> <20090121031500.GA2354@shareable.org> <20090121041604.GI24891@wotan.suse.de> <20090121045921.GA3944@shareable.org> <20090121062306.GK24891@wotan.suse.de> <20090121121308.GA31253@mit.edu> <20090121123711.GA10637@shareable.org> <20090121141207.GD31253@mit.edu> <1232548550.17244.3.camel@think.oraclecorp.com> <20090121204105.GA16133@shareable.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Chris Mason , Theodore Tso , Nick Piggin , linux-fsdevel@vger.kernel.org, Eric Sandeen To: Jamie Lokier Return-path: Received: from g1t0026.austin.hp.com ([15.216.28.33]:48379 "EHLO g1t0026.austin.hp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751546AbZAUVYB (ORCPT ); Wed, 21 Jan 2009 16:24:01 -0500 In-Reply-To: <20090121204105.GA16133@shareable.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Jamie Lokier wrote: > > Does O_DIRECT on btrfs still allocate new data blocks? > That's not very direct :-) > > I'm thinking if O_DIRECT is set, considering what's likely to request > it, it may be reasonable for it to mean "overwrite in place" too > (except for files which are actually COW-shared with others of course). O_DIRECT for databases is to bypass the OS file data cache. Those (oracle) who have long experience with it on unix know that the physical storage location can change on a filesystem. I do not think we want to make a special case, it should be up to the db admin to choose cow/nocow because if they want SNAPSHOTS they need cow. jim