From: "Mark H. Wood" <mwood@IUPUI.Edu>
To: linux-lvm@redhat.com
Subject: Re: [linux-lvm] Forcing the lvconvert copy to be on a different physical disk
Date: Tue, 2 Jul 2013 11:09:02 -0400 [thread overview]
Message-ID: <20130702150902.GD27779@IUPUI.Edu> (raw)
In-Reply-To: <CAFrGbuWP-aqh8MvGND=0rvuvXtpXqApBXAWxp-yi_ftnoxasWw@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1347 bytes --]
On Mon, Jul 01, 2013 at 12:48:14PM +0200, Alessandro MACUZ wrote:
> in my company they want to use LVM to handle a transition period while
> moving VM guests from local datastore to a NAS (via iSCSI)
>
> An example with numbers is worth thousands of words.
> The idea is to have one leg locally and one leg on the NAS, then we'll
> remove the local leg and tha machine will run with the leg on the NAS.
>
> So there are two MBR-partitioned vdisks, 10G each, and with one big LVM
> partition (0x8e)
>
> I have created one VG spanning both disks and one LV hosted on the local
> disk.
>
> How to tell lvconvert that the mirror, of the LV I want, must entirely be
> hosted on the second disk?
It looks as though you simply specify the PV from which you want to
allocate the new extents, after the LV you are mirroring. That is, if
you have a logical volume "LV" on /dev/sda1 and you want to mirror it
onto /dev/sdb1:
lvconvert -m1 LV /dev/sdb1
Later I think you would do likewise to remove the local image from
/dev/sda1, leaving the image on /dev/sdb1:
lvconvert -m0 LV /dev/sda1
*I have not yet done this*. Please try it out on a test machine
before risking production data.
--
Mark H. Wood, Lead System Programmer mwood@IUPUI.Edu
Machines should not be friendly. Machines should be obedient.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
next prev parent reply other threads:[~2013-07-02 15:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-01 10:48 [linux-lvm] Forcing the lvconvert copy to be on a different physical disk Alessandro MACUZ
2013-07-02 15:09 ` Mark H. Wood [this message]
2013-07-02 15:56 ` Alessandro MACUZ
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=20130702150902.GD27779@IUPUI.Edu \
--to=mwood@iupui.edu \
--cc=linux-lvm@redhat.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 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).