Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: "Austin S. Hemmelgarn" <ahferroin7@gmail.com>
To: Christoph Anton Mitterer <calestyo@scientia.net>,
	linux-btrfs@vger.kernel.org
Subject: Re: [PATCH v3] btrfs: Introduce new mount option to disable tree log replay
Date: Mon, 14 Dec 2015 15:20:54 -0500	[thread overview]
Message-ID: <566F24A6.8040605@gmail.com> (raw)
In-Reply-To: <1450122242.6629.45.camel@scientia.net>

On 2015-12-14 14:44, Christoph Anton Mitterer wrote:
> On Mon, 2015-12-14 at 14:33 -0500, Austin S. Hemmelgarn wrote:
>> The traditional reasoning was that read-only meant that users
>> couldn't
>> change anything
> Where I'd however count the atime changes to.
> The atimes wouldn't change magically, but only because the user stared
> some program, configured some daemon, etc. ... which reads/writes/etc.
> the file.
But reading the file is allowed, which is where this starts to get 
ambiguous.  Reading a file updates the atime (and in fact, this is the 
way that most stuff that uses them cares about them), but even a ro 
mount allows reading the file.  The traditional meaning of ro on UNIX 
was (AFAIUI) that directory structure couldn't change, new files 
couldn't be created, existing files couldn't be deleted, flags on the 
inodes couldn't be changed, and file data couldn't be changed.  TBH, I'm 
not even certain that atime updates on ro filesystems was even an 
intentional thing in the first place, it really sounds to me like the 
type of thing that somebody forgot to put in a permissions check for, 
and then people thought it was a feature.
>
>
>> , not that the actual data on disk wouldn't change.
>> That, and there's been some really brain-dead software over the years
>> that depended on atimes being right (now, the only remaining software
>> I
>> know of that even uses them at all is Mutt).
> Wasn't tmpwatcher anoterh candidate?
Most such software can use it, but doesn't depend on it.  TBH, many 
people these days run /tmp (and even /var/tmp) on an in memory 
filesystem, so atime updates aren't as much of an issue there.  Also, 
even with noatime, I'm pretty sure the VFS updates the atime every time 
the mtime changes (because not doing so would be somewhat stupid, and 
you're writing the inode anyway), which technically means that stuff 
could work around this by opening the file, truncating it to the size it 
already is, and then closing it.
>
>
>> This should be 'Nothing on the backing device may change as a result
>> of
>> the FS', nitpicking I know, but we should be specific so that we
>> hopefully avoid ending up in the same situation again.
> Of course, you're right! :-)
>
> (especially when btrfs should ever be formalised in a standards
> document, this should read like:
>> hard-ro: Nothing on the backing device may change as a result of the
>> FS, however, e.g. maleware, may directly destroy the data on the
>> blockdevice ;-)
>
>
> Chris.
>


  reply	other threads:[~2015-12-14 20:21 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-10  2:34 [PATCH v3] btrfs: Introduce new mount option to disable tree log replay Qu Wenruo
2015-12-14 17:32 ` David Sterba
2015-12-14 17:50   ` Austin S. Hemmelgarn
2015-12-14 19:16     ` Christoph Anton Mitterer
2015-12-14 19:33       ` Austin S. Hemmelgarn
2015-12-14 19:44         ` Christoph Anton Mitterer
2015-12-14 20:20           ` Austin S. Hemmelgarn [this message]
2015-12-14 23:34             ` Christoph Anton Mitterer
2015-12-15 13:31               ` Austin S. Hemmelgarn
2015-12-16 13:53     ` David Sterba
2015-12-14 19:11   ` Christoph Anton Mitterer
2015-12-16  1:36   ` Qu Wenruo
2015-12-16  2:13     ` Christoph Anton Mitterer
2015-12-16 11:10     ` Duncan
2015-12-16 11:45       ` Christoph Anton Mitterer
2015-12-17  1:09         ` Duncan
2015-12-17  1:46           ` Christoph Anton Mitterer
2015-12-16 12:12       ` Austin S. Hemmelgarn
2015-12-16 12:34         ` Christoph Anton Mitterer
2015-12-16 12:57           ` Austin S. Hemmelgarn
2015-12-16 13:01             ` Christoph Anton Mitterer
2015-12-16 13:58     ` David Sterba

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=566F24A6.8040605@gmail.com \
    --to=ahferroin7@gmail.com \
    --cc=calestyo@scientia.net \
    --cc=linux-btrfs@vger.kernel.org \
    /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