From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jamie Lokier Subject: Re: [RFC PATCH] Filesystem Journal Notifications Date: Wed, 17 Sep 2008 12:35:22 +0100 Message-ID: <20080917113522.GB22613@shareable.org> References: <20080912220649.GB26999@apaithan-desktop.sanmateo.corp.akamai.com> <20080915132357.GA10973@shareable.org> <20080917000600.GA30388@apaithan-desktop.sanmateo.corp.akamai.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel@vger.kernel.org, Andreas Dilger To: Abhijit Paithankar Return-path: Received: from mail2.shareable.org ([80.68.89.115]:35138 "EHLO mail2.shareable.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752373AbYIQLfZ (ORCPT ); Wed, 17 Sep 2008 07:35:25 -0400 Content-Disposition: inline In-Reply-To: <20080917000600.GA30388@apaithan-desktop.sanmateo.corp.akamai.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Abhijit Paithankar wrote: > > > One way to do it is to fsync every few operations. However, fsync is > > > blocking and affects performance. > > > > > > The other (more efficient) way is to have the filesystem notify the > > > application when a transaction/change is written to disk. > > > > Is this more efficient than aio_fsync, and if so, why? > > > > For file writes, aio_fsync seems like a cleaner interface, and if > > that's not fast enough, it could be made faster - perhaps using code > > form this patch. (An aio_fsync_ranges would be even better). > > aio_fsync does not provide any relationship between the metadata > operations and journal commit. There is no mechanism to track > operations which made it to the journal and the ones that did not. Oh, do you mean that aio_fsync tells you all operations have reached the journal up to the time of aio_fsync, but your notifications say _which_ operations reach it one at a time, so you can wait on specific ones without waiting for them all? If the latter, I agree that what you're doing is good :-) -- Jamie