can snapshots become corrupted ? Is fsck'ing /dev/md0 sensible ?
olli at lurza.secnetix.de
Sat Jan 21 12:58:27 PST 2006
Joe Schmoe <non_secure at yahoo.com> wrote:
> On Sat, 21 Jan 2006, Oliver Fromme wrote:
> > Yes, the snapshot is probably still "dirty". But it
> > shouldn't matter, because you can only mount it read-only
> > anyway.
> Ok, yes, the snapshot can only be mounted read-only -
> this is true. However, the snapshot itself (whether
> mounted or not) is continually being changed as files
> are being changed or deleted on the filesystem in
> question. So if the snapshot is corrupt, and I start
> making changes/deletions on the (now clean)
> filesystem, then wouldn't there be problems ?
That question would have to be answered by a snapshots
expert. But I guess you're right, there are probably
> Ok, understood. However, once I do a full and
> successful fsck on that filesystem, it is completely
> safe again, regardless of how long or how often I ran
> it while it was dirty, right ?
Right, provided the dirtyness was only soft-updates
related and the disks were reliable.
> The second question I need to ask is, when I am
> rsyncing this filesystem to a remote host, why is it
> not a read-only operation ? My rsync process, because
> this filesystem was the _source_, and not the
> destination, should not have written anything to this
> filesystem. However, it succeeded when the fs was
> read-only (softupdates were off) and it failed when
> the filesystem was read-write (softupdates on). Is
> there some kind of manipulation of the source
> filesystem that rsync does that would be equal to a
> lot of writing to the source disk ?
When you read from a file, its atime (access time) is
scheduled for an update (unless the FS is mounted with
the "noatime" flag). That's a write operation.
So when you rsync a lot of files, quite a lot of meta
data updates can pile up. That happens only if the
FS is mounted read-write, of course.
> It is my understanding that soft-updates only deal
> with writes to the disk
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing
Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd
Any opinions expressed in this message may be personal to the author
and may not necessarily reflect the opinions of secnetix in any way.
"Being really good at C++ is like being really good
at using rocks to sharpen sticks."
-- Thant Tessman
More information about the freebsd-fs