retry mounting with ro when rw fails

Andriy Gapon avg at FreeBSD.org
Fri Apr 8 15:20:51 UTC 2011


on 08/04/2011 15:20 Bruce Evans said the following:
> But the default behaviour is backwards, especially for read-mostly
> removable media.  The default should be ro, possibly with an automagic
> upgrade to rw iff the media really needs to be written too.  Writing
> timestamps for file system and inode access times doesn't count as
> "really needs to be written to".
> 
> I think I prefer requiring an explicit upgrade to rw.  rw implies
> writing access times unless you also use noatime, and I wouldn't want
> noatime to be set automagically depending on whether rw is set explicitly,
> so I would want noatime to be set explicitly, and once you do that
> then you can easily set rw or ro at the same time.  A new rm (read mostly)
> or "rwa" (read or write automagically) flag could give automatic upgrade
> from ro to rw.  I'd also like automatic downgrade to ro after a file
> system has not been written to for some time (this would avoid fscks
> in most cases for read-mostly file systems.  The ro flag should be
> per-cylinder-group in ffs so that on big disks, most parts are read-only
> most of the time and don't need to be checked).

This is a very good idea, I would like to get that too, but it's a bit more work
than the "auto"-mounting.

-- 
Andriy Gapon


More information about the freebsd-hackers mailing list