All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans Reiser <reiser@namesys.com>
To: "Ragnar Kjørstad" <reiserfs@ragnark.vestdata.no>
Cc: reiserfs-list@namesys.com
Subject: Re: Agressive selective pre-allocation
Date: Thu, 12 Dec 2002 17:46:08 +0300	[thread overview]
Message-ID: <3DF8A130.7070101@namesys.com> (raw)
In-Reply-To: <20021212094754.S26400@vestdata.no>

Ragnar Kjørstad wrote:

>On Tue, Dec 10, 2002 at 12:12:28PM +0100, Stefan Fleiter wrote:
>  
>
>>>mbox's aren't an issue, if you have them then you probably don't care too
>>>much about performance anyway.
>>>      
>>>
>>I switched some large mailing lists with thousands of messages from mbox to
>>maildir with mutt. Changing mailboxes lasted maybe 2 or 3 times longer,
>>so I switched back to mbox *for speed*.
>>    
>>
>
>Yes, maildir is not always faster.
>
>First problem is disk-layout. The way it works with reiserfs3.6 and
>default hashes the inodes and files are written in different orders and
>the disk does a lot of unneeded seeks. 
>
You mean the names are written in an order different from the stat data 
and file bodies, and the stat data and file bodies have the same order.

This is because we sort filenames by filename, and  sort stat data and 
file bodies by objectid which tends to be ordered by creation time.

We should implement a plugin that sorts filenames by creation time, and 
that will cause our performance to resemble ext2 more (meaning that for 
large directories the performance will fall apart, but for small 
directories there might be some advantage from not sorting by name).  I 
think that sorting file bodies by filename would require a larger key, 
so I hesitate at that, but maybe it would be interesting to explore also.

>A workaround is to use a hash
>that automagicly orders inodes and files the same way. A better way is
>probably to store the stat-data with the directory-data. I think that is
>on the schedule, is it not?
>
No, not yet, it didn't make the 4.0 code freeze....  patches are 
welcomed....

>
>It is also important that readdir-order matches the ondisk layout, but
>that is perhaps already the case?
>
If you copy a directory, then after the copy the readdir order matches 
the ondisk layout.

>
>Possible the overhead of the systemcalls is also significant, but my
>guess is that it is negletable compared to io-performance.
>
>Next problem is readahead. When the whole mailbox is in a single file
>the OS is able to use readahead to improve performance, but it doesn't
>seem to work as well when reading a whole directory. This is perhaps the
>thoughest one to solve, IMHO.
>
It is not very hard to solve if we use packing locality readahead.

>
>
>However, the single most important fix would be the mail-clients. If I'm
>not mistaken mutt reads the whole mail, and that's simply not required.
>It should only read the headers. That will speed things up by a huge
>factor when you have mails with attachments and so on.  It must also learn 
>that it shouldn't reread the folder everytime it's updated!
>
>Right now the case is pretty much that none or few of the potential
>performance-benefits of maildir are made use of, and the drawbacks are
>hitting much harder then they ought to. I bet it's only temporary
>though. Reiserfs has the potential to make faster mailsystems with
>the use of maildir! :-)
>
>
>
>  
>



  reply	other threads:[~2002-12-12 14:46 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-10  6:46 Agressive selective pre-allocation Ragnar Kjørstad
2002-12-10  7:26 ` Russell Coker
2002-12-10  7:58   ` Ragnar Kjørstad
2002-12-10 11:12   ` Stefan Fleiter
2002-12-12  8:47     ` Ragnar Kjørstad
2002-12-12 14:46       ` Hans Reiser [this message]
2002-12-14  1:56         ` Ragnar Kjørstad
2002-12-10 14:13 ` Hans Reiser
2002-12-14  2:06   ` Ragnar Kjørstad
2002-12-10 16:43 ` Bruce A. Mallett
2002-12-10 17:17   ` Anders Widman
2002-12-14  2:09   ` Ragnar Kjørstad

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=3DF8A130.7070101@namesys.com \
    --to=reiser@namesys.com \
    --cc=reiserfs-list@namesys.com \
    --cc=reiserfs@ragnark.vestdata.no \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.