linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
From: "Bryn M. Reeves" <bmr@redhat.com>
To: lvm@beer.org.uk,
	LVM general discussion and development <linux-lvm@redhat.com>
Subject: Re: [linux-lvm] Fun and games with mirroring
Date: Tue, 22 May 2012 17:00:52 +0100	[thread overview]
Message-ID: <4FBBB834.302@redhat.com> (raw)
In-Reply-To: <54088.172.16.0.29.1337700576.squirrel@beer.org.uk>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 05/22/2012 04:29 PM, Vic wrote:
> 
>> How is it different/better than 'mdadm --fail' ing a member out
>> of an MD raid1 set as a temporary snapshot?
> 
> You can do it to a box that hasn't been set up with mdadm...

Sure but you will need LVM set up. In that case, why not use LVM's
snapshot capabilities? If you're using a distribution with a recent
kernel then you'll have access to the new shared snapshot
implementation that gives far better performance than the old
non-shared one.

Some distributions (yum based) even include a package updater plug-in
that will automatically take snapshots before applying a set of
package updates and allow you to either rollback or merge the change
after testing.

You might find this works better for this particular use of mirroring
but you can also try the --splitmirrors option to the lvconvert
command (but it will be less efficient since it will take a
block-by-block copy of the origin during the lvconvert -m1 rather than
just recording changes as a snapshot would). Mirror splitting was
added in 2.02.88 (about nine months old).

I've found that dracut doesn't always handle LVM errors particularly
gracefully (in particular if there is a problem the dracut main loop
appears to reset state after leaving the interactive shell so even if
you do fix the problem such that the system could continue to boot it
will just fail in the same way again) and by the sound of it this
could be improved for your case too.

Ideally you'd want the initramfs scripts to carry out the same actions
as the defined mirror repair policy during startup (or to invoke
lvconvert --repair to do the same).

Regards,
Bryn.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk+7uDQACgkQ6YSQoMYUY95ECwCgkcYwE6ujXi5rLOApVZg5wSWN
pj8An05qCXCcaOSt+sgOZvpYORKHU4gM
=zW6z
-----END PGP SIGNATURE-----

  reply	other threads:[~2012-05-22 16:00 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-22 14:50 [linux-lvm] Fun and games with mirroring Vic
2012-05-22 15:27 ` Les Mikesell
2012-05-22 15:29   ` Vic
2012-05-22 16:00     ` Bryn M. Reeves [this message]
2012-05-22 16:40       ` Vic
2012-05-22 19:24         ` Brassow Jonathan
2012-05-22 19:59           ` Vic
2012-05-23  8:52             ` Bryn M. Reeves
2012-05-23 10:02             ` Zdenek Kabelac
2012-05-23 15:16             ` Brassow Jonathan
2012-05-23  8:54         ` Bryn M. Reeves
2012-05-23 15:21           ` Les Mikesell
2012-05-23 15:36             ` Bryn M. Reeves
2012-05-23 17:03               ` Les Mikesell
2012-05-23 17:24                 ` Bryn M. Reeves
2012-05-23 18:00                   ` Les Mikesell
2012-05-23 18:32                     ` Stuart D Gathman
2012-05-23 19:07                       ` Les Mikesell
2012-05-23 22:39                         ` Stuart D Gathman
2012-05-22 17:57 ` Stuart D Gathman
2012-05-22 18:39   ` tariq wali
2012-05-23 22:44     ` Stuart D Gathman

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=4FBBB834.302@redhat.com \
    --to=bmr@redhat.com \
    --cc=linux-lvm@redhat.com \
    --cc=lvm@beer.org.uk \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).