Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 04 Apr 2000 12:36:22 -0600
From:      Warner Losh <imp@village.org>
To:        "Jeffrey S. Sharp" <jss@subatomix.com>
Cc:        "freebsd-small" <freebsd-small@FreeBSD.ORG>
Subject:   Re: Mounting and Corruption Rehashed 
Message-ID:  <200004041836.MAA70239@harmony.village.org>
In-Reply-To: Your message of "Tue, 04 Apr 2000 14:16:05 CDT." <001f01bf9e6a$3a0b3c00$2aa85c0a@vulcan> 
References:  <001f01bf9e6a$3a0b3c00$2aa85c0a@vulcan>  

next in thread | previous in thread | raw e-mail | index | archive | help
In message <001f01bf9e6a$3a0b3c00$2aa85c0a@vulcan> "Jeffrey S. Sharp" writes:
: Let's set the way-back knob to a few months ago.  We were discussing the
: viability of doing the following:
: 
: *  Mounting flash read-only on /
: *  Mounting small MFS filesystems on /var and /tmp
: *  Temporarily remounting / read-write to make changes
: 
: The problem was this little paragraph from `man mount`:
: 
: > Switching a filesystem back and forth between asynchronous
: > and normal op­eration or between read/write and read/only
: > access using ``mount -u'' may gradually bring about severe
: > filesystem corruption.
: 
: Someone spoke up and said that they had actually experienced this
: corruption.

I've not seen corruption.  However, I oly change one or two files
somewhat infrequently and tend to reboot often when I'm changing the
underlying filesystem.

: Please excuse me if the following is a dumb question: why even mount the
: flash _read-only_ in the first place?  If /var and /tmp are on separate
: filesystems (MFS), what write operations are going to happen to the flash
: that mounting read-only would prevent?

The superblock gets updated from time to time.  Also, when things are
mounted r/o you can power off at any time and know that the filesystem
will be stable when you come back.  I've had some problems in the past
where I've trashed a filesystem that was mounted r/w by doing this at
just the wrong time even though there wasn't much activity.  Mounting
R/O ensures that you don't accidentally do writes as well.

Warner


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-small" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200004041836.MAA70239>