xfs
[Top] [All Lists]

Re: logging of metadata ops

To: Stewart Smith <stewart@xxxxxxxxxxxxxxxx>
Subject: Re: logging of metadata ops
From: David Chinner <dgc@xxxxxxx>
Date: Mon, 13 Mar 2006 08:25:20 +1100
Cc: Linux-xfs@xxxxxxxxxxx
In-reply-to: <1142005498.9240.63.camel@localhost.localdomain>
References: <1142005498.9240.63.camel@localhost.localdomain>
Sender: linux-xfs-bounce@xxxxxxxxxxx
User-agent: Mutt/1.4.2.1i
On Fri, Mar 10, 2006 at 04:44:57PM +0100, Stewart Smith wrote:
> on creat(), write(), close() of a file in a directory, at what point is
> the creation of the file and its addition to the directory flushed to
> the log on disk?

Seeing as they are async transactions, they typically get flushed to
disk when the iclogbuf has no more space available.

> For MyISAM this would mean creating 3,000,000 files in a directory.
> Currently I'm seeing about 100 table creates/sec (so about 300
> files/sec) although bonnie++ shows 716 file creations per second.

For how many files in the bonnie run? If the number of inodes is
small enough that you don't fill the log and cause tail pushing
(i.e. actually writing metadata buffers to disk), then the bonnie
numbers will be misleadingly high - they'll be peak numbers instead
of sustained throughput.....

> So, since MySQL is also writing data to these files, could anything
> interesting be happening with the log?

Data writes will increase log traffic due to allocation transactions
and it will also increase disk seeks. Both of these will slow the
create rate down.

> It's also quite possible that MySQL is the bottleneck here and we should
> be able to do 716/3=238 table creations/sec.
> 
> Although it'd be good to know if that number could be improved upon
> simply by tuning the FS log.

v2 log, mount with "-o logbsize=256k".

Cheers,

Dave.
-- 
Dave Chinner
R&D Software Enginner
SGI Australian Software Group


<Prev in Thread] Current Thread [Next in Thread>