Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Jul 2002 02:22:55 -0400
From:      "Mark W. Krentel" <krentel@dreamscape.com>
To:        freebsd-fs@freebsd.org
Subject:   Is linux dump broken?
Message-ID:  <200207130622.g6D6Mt501210@dreamscape.com>

next in thread | raw e-mail | index | archive | help
A thousand pardons for asking a Linux question here.  But I'm seeing a
serious problem with the Linux dump and I need someone to compare how
Freebsd handles this and restore sanity to my world.

Basically, the Linux dump doesn't handle mounted partitions correctly.
You can dump a mounted partition, but writes since the last incremental
don't show up until the partition is unmounted.  It's a file system
cache problem, dump doesn't notice in-memory changes to the file
system until they're flushed to disk.  And I don't mean writing to a
file during the dump.  You can reproduce the problem with dump, write,
dump, restore.  (And actually, it's writes without O_TRUNC that are
missed.)

I was incredulous.  I asked about this on dump-users on sourceforge
and got the following answer:

    And the inconsistency is normal, because both dump and the kernel
    accesses the raw disk structures directly, without synchronisation.

    This is a known problem, due to dump's design, which was no never
    run dump on mounted filesystems. Unless you either umount the
    filesystem first or use some kind of filesystem snapshots (LVM etc),
    you cannot guarantee that your files were in a consistent state.
    That's why you should check your backup with restore -C each time.

So, my questions are:

(1) Is this supposed to work?  If a write completes before dump is
started, is dump required to see the change, even if it's still in
memory?  My contention is yes, or else dump is seriously broken.

(2) Does it work in Freebsd?  My tests suggest yes, but maybe I
haven't found the hardest counter example.

(3) What's up with Linux?  Did they not port dump correctly, or does
ext2 make this impossible?

Thanks,

--Mark

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




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