linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Jonathan Tripathy <jonnyt@abpni.co.uk>
To: linux-lvm@redhat.com
Subject: Re: [linux-lvm] Snapshots and disk re-use
Date: Wed, 06 Apr 2011 01:50:35 +0100	[thread overview]
Message-ID: <4D9BB8DB.6070906@abpni.co.uk> (raw)
In-Reply-To: <4D9BB703.3030101@ankh.org>



On 06/04/2011 01:42, James Hawtin wrote:
> On 06/04/2011 00:28, Jonathan Tripathy wrote:
>> Ok, i think I get it now. At the minute, my vg (vg0) only has on PV 
>> in it (/dev/md3 which you can tell is a mdadm RAID device). I wasn't 
>> aware you could add more PVs (that's pretty cool!). So, let's say I 
>> had a spare partition (/dev/hdb7 as an example). To my vg0 volume 
>> group, I would firstly:
>>
>> pvcreate /dev/hdb7
>> vgextend /dev/hdb7
>
> Right however danger warnings are going off in my mind now!
>
>> Then, every time I create a new customer LV, I would do:
>>
>> lvcreate -nNewCustomerLV -L20G vg0 /dev/md3
>
> yes that would work
>
>>
>> Then, every time I wanted to create a snapshot:
>>
>> lvcreate -L20G -s -n data_snap /dev/vg0/NewCustomerLV /dev/hdb7
>>
>
> Yes
>
>> Is that correct? No Leakage? And no zeroing needed?
> Indeed
>
>>
>> Side note: Since I didn't partition my servers with this in mind, my 
>> new PV will probably have to be an iSCSI device located on a remote 
>> target :( Either that or use a loopback device with an image, but I'd 
>> be scared that the system would not boot properly. Can you give me 
>> any tips on how to use an image file as a PV just for snapshots?
>
> Ok, there has been alot of dangerous talk here, i assume you are using 
> an md device so you can mirror things. 
Correct
> If you added a single disk to that, and that disk failed you would 
> have a major problem. Likewise if you rebooted with open snaps and 
> iscsi you would need that iscsi device available during computer boot. 
> I REALLY hope you do not have your local FS on the same vg as your 
> data. As this would result in a non booting machine.
Nope. My root partition is not on LVM at all, but just on a regular md 
partition. The LVM LVs are used for virtual machine hosting for 
customers. Also, I used just /dev/hdb7 as an example, but it does bring 
up some interesting questions:

If the PV used for snapshots were to fail while the snapshot was open, 
or the server rebooted and the PV wasn't available at boot, what would 
happen? I ask these questions because a loopback device or iSCSI is 
really my only feasible option right now for the snapshot PV...

  reply	other threads:[~2011-04-06  0:50 UTC|newest]

Thread overview: 68+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-23 12:36 [linux-lvm] Snapshots and disk re-use Jonathan Tripathy
2011-02-23 13:09 ` Joe Thornber
2011-02-23 13:57   ` Jonathan Tripathy
2011-02-23 14:16     ` Joe Thornber
2011-02-23 14:18       ` Jonathan Tripathy
2011-02-23 16:12         ` Ray Morris
2011-02-23 16:55           ` Jonathan Tripathy
2011-02-23 17:54             ` Stuart D. Gathman
2011-02-23 18:05               ` Jonathan Tripathy
2011-02-23 19:34                 ` Stuart D. Gathman
2011-02-23 18:05               ` Stuart D. Gathman
2011-02-23 18:19                 ` Jonathan Tripathy
2011-02-23 18:39                   ` Les Mikesell
2011-02-23 19:39                     ` Stuart D. Gathman
2011-02-23 20:03                       ` Les Mikesell
2011-02-23 20:37                         ` Stuart D. Gathman
2011-02-23 20:49                           ` Jonathan Tripathy
2011-02-23 23:25                             ` Stuart D. Gathman
2011-02-23 23:42                               ` Stuart D. Gathman
2011-02-24  0:09                               ` Jonathan Tripathy
2011-02-24  0:32                                 ` Stuart D. Gathman
2011-02-24  0:37                                   ` Jonathan Tripathy
2011-02-24  0:40                                     ` Jonathan Tripathy
2011-02-24  2:00                                       ` Stuart D. Gathman
2011-02-24  7:33                                         ` Jonathan Tripathy
2011-02-24 14:50                                           ` Stuart D. Gathman
2011-02-24 14:57                                             ` Jonathan Tripathy
2011-02-24 15:13                                               ` Stuart D. Gathman
2011-02-24 15:20                                                 ` Jonathan Tripathy
2011-02-24 16:41                                                   ` Jonathan Tripathy
2011-02-24 19:15                                                     ` Nataraj
2011-02-24 19:25                                                       ` Les Mikesell
2011-02-24 19:55                                                       ` Stuart D. Gathman
2011-02-24 19:19                                                     ` Stuart D. Gathman
2011-02-24 19:45                                                   ` Stuart D. Gathman
2011-02-24 21:22                                                     ` Jonathan Tripathy
2011-04-05 20:09                                                   ` Jonathan Tripathy
2011-04-05 20:41                                                     ` Stuart D. Gathman
2011-04-05 20:48                                                       ` Jonathan Tripathy
2011-04-05 20:59                                                         ` James Hawtin
2011-04-05 21:36                                                           ` Jonathan Tripathy
2011-04-05 22:42                                                             ` James Hawtin
2011-04-05 22:52                                                               ` Jonathan Tripathy
2011-04-05 23:11                                                                 ` James Hawtin
2011-04-05 23:19                                                                   ` Jonathan Tripathy
2011-04-05 23:39                                                                     ` James Hawtin
2011-04-06  0:00                                                                       ` Jonathan Tripathy
2011-04-06  0:08                                                                         ` Stuart D. Gathman
2011-04-06  0:14                                                                           ` Jonathan Tripathy
2011-04-06  0:16                                                                         ` James Hawtin
2011-04-06  0:28                                                                           ` Jonathan Tripathy
2011-04-06  0:38                                                                             ` Stuart D. Gathman
2011-04-06  0:43                                                                               ` Stuart D. Gathman
2011-04-06  1:36                                                                                 ` James Hawtin
2011-04-06  1:47                                                                                   ` Jonathan Tripathy
2011-04-06  1:53                                                                                     ` James Hawtin
2011-04-06  0:47                                                                               ` Jonathan Tripathy
2011-04-06  0:42                                                                             ` James Hawtin
2011-04-06  0:50                                                                               ` Jonathan Tripathy [this message]
2011-04-06  1:20                                                                                 ` James Hawtin
2011-04-06  1:45                                                                                   ` Jonathan Tripathy
2011-02-23 19:49                     ` Nataraj
2011-02-23 19:24                   ` Stuart D. Gathman
2011-02-23 19:07                 ` [linux-lvm] Problem executing lvm related commands Tinni
2011-02-23 19:33               ` [linux-lvm] Snapshots and disk re-use Phillip Susi
2011-02-23 19:45                 ` Stuart D. Gathman
2011-02-23 19:56                   ` Nataraj
2011-02-23 13:18 ` Sunil_Gupta2

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=4D9BB8DB.6070906@abpni.co.uk \
    --to=jonnyt@abpni.co.uk \
    --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).