[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

fts and O_NOATIME

From: Eric Blake
Subject: fts and O_NOATIME
Date: Thu, 07 Jul 2011 07:50:24 -0600
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20110428 Fedora/3.1.10-1.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.10

http://savannah.gnu.org/bugs/?33724 raised the issue that findutils is
updating directory atime as part of traversing a hierarchy (and,
according to POSIX, this behavior is the correct default).  However, it
would be nice to support the use of fts in a mode where O_NOATIME is
used, so that directories don't appear to have an atime change merely
because fts called readdir.

It looks to me like the only way to do this is to use open(O_NOATIME)
followed by fdopendir() - but we are already using this approach for
other reasons.  So would it be worth a patch that adds a new FTS_NOATIME
flag, and when that flag is set, pass in the O_NOATIME flag to all
directories opened by fts?

Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]