From: Anton Altaparmakov <aia21@cam.ac.uk>
To: "Charles P. Wright" <cpwright@cpwright.com>
Cc: Szakacsits Szabolcs <szaka@sienet.hu>, linux-fsdevel@vger.kernel.org
Subject: Re: Postmark on NTFS
Date: Fri, 08 Aug 2003 10:48:46 +0100 [thread overview]
Message-ID: <1060336126.6965.8.camel@imp> (raw)
In-Reply-To: <Pine.LNX.4.44.0308071440130.20289-100000@cpwright.com>
On Thu, 2003-08-07 at 20:08, Charles P. Wright wrote:
> Does NTFS have more synchronous writes or reads than Ext3?
Yes, loads more. All metadata writes must either be synchronous OR they
must use double buffering. Both cases make it slower than a simple
write to disk which can be asynchronous.
This is because metadata in ntfs is not written as it is in memory but
it is modified - fixups are applied which allow checking for
corruption/crashes on read from disk.
In the direct write case the metadata is then written to disk, and then
the modifications are undone. Obviously, during the time in which the
metadata is modified, you cannot change the metadata as for all intents
and purposes it is corrupt and unusable. This makes it impossible to
make any changes while a write is in progress and all changes are
stalled till the write is completed and the fixups are undone.
In the double buffered case the metadata is copied, then fixups applied,
then written to disk, and then thrown away. There is one complication
and that is that the original in-memory metadata must be modified as
well to reflect the fact that it was just written to disk (the fixup
counter is incremented by one) so even here there is a short period of
time during which the original metadata cannot be touched by anyone
else.
I opted for the direct write approach in the Linux ntfs driver and as
far as I have understood the windows ntfs driver, it uses the direct
write approach, too.
Ext3 doesn't do such metadata fixups which allows its writes to be more
flexibly managed.
Best regards,
Anton
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Unix Support, Computing Service, University of Cambridge, CB2 3QH, UK
Linux NTFS maintainer / IRC: #ntfs on irc.freenode.net
WWW: http://linux-ntfs.sf.net/ &
http://www-stu.christs.cam.ac.uk/~aia21/
prev parent reply other threads:[~2003-08-08 9:48 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-07 17:04 Postmark on NTFS Charles P. Wright
2003-08-07 18:01 ` Szakacsits Szabolcs
2003-08-07 19:08 ` Charles P. Wright
2003-08-07 20:02 ` Szakacsits Szabolcs
2003-08-08 9:48 ` Anton Altaparmakov [this message]
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=1060336126.6965.8.camel@imp \
--to=aia21@cam.ac.uk \
--cc=cpwright@cpwright.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=szaka@sienet.hu \
/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