xfs
[Top] [All Lists]

Re: Documenting MS_LAZYTIME

To: Andreas Dilger <adilger@xxxxxxxxx>
Subject: Re: Documenting MS_LAZYTIME
From: "Michael Kerrisk (man-pages)" <mtk.manpages@xxxxxxxxx>
Date: Fri, 20 Feb 2015 14:22:07 +0100
Cc: "Theodore Ts'o" <tytso@xxxxxxx>, Ext4 Developers List <linux-ext4@xxxxxxxxxxxxxxx>, Linux btrfs Developers List <linux-btrfs@xxxxxxxxxxxxxxx>, XFS Developers <xfs@xxxxxxxxxxx>, linux-man <linux-man@xxxxxxxxxxxxxxx>, Linux-Fsdevel <linux-fsdevel@xxxxxxxxxxxxxxx>, Linux API <linux-api@xxxxxxxxxxxxxxx>
Delivered-to: xfs@xxxxxxxxxxx
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:in-reply-to:references:from:date:message-id :subject:to:cc:content-type:content-transfer-encoding; bh=7mIeM69a5GLCOvWj/iUeG/nYhgBBPK1qxUHOVBe/1DM=; b=FvH5qrtf77wTVBa4Ws4t9vIICWCtmIK+IlgcAjAx4JVOnj6EgZ397ISCfPsZwUmJB/ zBj8KatU7r1gSh7Me6iR80k1HQPRmWyQ//Fd7CJ42tXLoViJrz+afQLtOpa58Q3MWV9f 6htpVl/7CugT/1pBRZjY90yaz1CDDpzPJZ47p/7x4aTMWMsLs6wGwSBqn1rcLoyxtReb 4cMAR+ARA5cWrSVZldOTxMrqnX0oUkRVR7EoNUeKszZNlMuqV6HTtE20PoZyycRWz+XU b+7o5UYDvIPNlILPjzAOfcBODCyza22udRYBywNB0/7877PcMTbQTFJ4m2Z68oxiBp1c 4f5w==
In-reply-to: <44893EA7-B11A-469A-9911-6CE2E8B26EB4@xxxxxxxxx>
References: <CAHO5Pa0k7QkV_6BDjwTVxa7LV9tFyN9nGFFcSvOC6HYO08wfrw@xxxxxxxxxxxxxx> <44893EA7-B11A-469A-9911-6CE2E8B26EB4@xxxxxxxxx>
Reply-to: mtk.manpages@xxxxxxxxx
On 20 February 2015 at 13:32, Andreas Dilger <adilger@xxxxxxxxx> wrote:
> On Feb 20, 2015, at 1:50 AM, Michael Kerrisk <mtk.manpages@xxxxxxxxx> wrote:
>>
>> Hello Ted,
>>
>> Based on your commit message 0ae45f63d4e, I I wrote the documentation
>> below for MS_LAZYTIME, to go into the mount(2) man page. Could you
>> please check it over and let me know if it's accurate. In particular,
>> I added pieces marked with "*" below that were not part of the commit
>> message and I'd like confirmation that they're accurate.
>>
>> Thanks,
>>
>> Michael
>>
>> [[
>>       MS_LAZYTIME (since Linux 3.20)
>>              Only  update  filetimes (atime, mtime, ctime) on the in-
>>              memory version of the file  inode.   The  on-disk  timeâ
>>              stamps are updated only when:
>>
>>              (a)  the inode needs to be updated for some change unreâ
>>                   lated to file timestamps;
>>
>>              (b)  the application  employs  fsync(2),  syncfs(2),  or
>>                   sync(2);
>>
>>              (c)  an undeleted inode is evicted from memory; or
>>
>> *             (d)  more than 24 hours have passed since the i-node was
>> *                  written to disk.
>>
>>              This mount option significantly reduces  writes  to  the
>>              inode  table  for workloads that perform frequent random
>>              writes to preallocated files.
>>
>> *             As at Linux 3.20, this option is supported only on ext4.
>
> I _think_ that the lazytime mount option is generic for all filesystems.
> I believe ext4 has an extra optimization for it, but that's it.

Ah yes, looking at the code again, that makes sense. I think you're
right, and I've struck that last sentence. Thanks, Andreas.

Cheers,

Michael


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/

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