All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Mason <mason@suse.com>
To: Phil Howard <phil-reiserfs@ipal.net>
Cc: Matthew Toseland <mtoseland@blueyonder.co.uk>, reiserfs-list@namesys.com
Subject: Re: copying partition to partition, sector by sector, live
Date: 22 Apr 2002 19:39:11 -0400	[thread overview]
Message-ID: <1019518751.16727.39.camel@tiny> (raw)
In-Reply-To: <20020422232448.GE8407@vega.ipal.net>

On Mon, 2002-04-22 at 19:24, Phil Howard wrote:
> On Mon, Apr 22, 2002 at 11:47:55PM +0100, Matthew Toseland wrote:
> 
> | On Sun, Apr 21, 2002 at 08:39:55PM -0500, Phil Howard wrote:
> | > On Mon, Apr 22, 2002 at 02:07:33AM +0100, Matthew Toseland wrote:
> | > 
> | > | Ummm, LVM snapshots? (man lvcreate).
> | > 
> | > No.  Nothing to do with LVM.
> | I was suggesting a solution. Your problem is that reiserfs's metadata is
> | so dynamic that if you copy the partition while it is active, you end up
> | with metadata loss, which has to be fixed by reiserfsck. A possible
> | solution is to get a consistent snapshot. To do this, do:
> | 
> | lvcreate -n <snapshotname> -L 500M -v /dev/<vgname>/<partition name>
> | dd if=/dev/<vgname>/snapshotname of=/usr/local/temp/snapshot.img bs=1M
> | lvremove -f /dev/<vgname>/snapshotname
> | 
> | (1) 500M could be anything; it is the amount of space needed to log all
> | changes to the partition while the dd is going on; you can extend it later
> | but once it fills up completely, you're scr00d; presumably the dd will
> | return an error
> 
> Sounds like journaling at the sector level.
> 
> How does all that change get replayed after the snapshot is done?

The snapshots use a simple copy on write setup.  Before changing a block
on the source, the original is copied to the snapshot.  This allows for
very fast snapshot creation, and a moderate runtime cost doing the
copies.

When you're done with the backup, you can just delete the snapshot
without affecting the (now modified) original.

> 
> I'm starting to think it might be better to go back to using rsync on
> mounted filesystems.

It might.  Snapshots are very useful, but are best in databases and
other setups where you need to freeze the FS at a specific point in
time, and when you need an absolute minimum of application down time.

-chris



  reply	other threads:[~2002-04-22 23:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-21 18:16 copying partition to partition, sector by sector, live Phil Howard
2002-04-22  1:07 ` Matthew Toseland
2002-04-22  1:39   ` Phil Howard
2002-04-22 17:58     ` Jonathan Briggs
2002-04-22 18:58     ` Chris Mason
2002-04-22 23:28       ` Phil Howard
2002-04-23  0:40         ` The Amazing Dragon
2002-04-22 22:47     ` Matthew Toseland
2002-04-22 23:24       ` Phil Howard
2002-04-22 23:39         ` Chris Mason [this message]
2002-04-23  0:34       ` Valdis.Kletnieks
2002-04-23 22:17         ` Matthew Toseland

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=1019518751.16727.39.camel@tiny \
    --to=mason@suse.com \
    --cc=mtoseland@blueyonder.co.uk \
    --cc=phil-reiserfs@ipal.net \
    --cc=reiserfs-list@namesys.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.