All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jun'ichi Nomura <j-nomura@ce.jp.nec.com>
To: lvm-devel@redhat.com
Subject: [LVM2 PATCH] Fix lvcreate's checking of the number of PVs
Date: Thu, 13 Sep 2007 18:11:49 -0400	[thread overview]
Message-ID: <46E9B5A5.1090209@ce.jp.nec.com> (raw)
In-Reply-To: <46E82DAB.9080805@ce.jp.nec.com>

Jun'ichi Nomura wrote:
> While not explained in man page, lvcreate can take tags of PVs
> as a specification of allocatable PVs.
> e.g. if you have 2 MD RAID1 disks and other disks in your vg,
>       you can do:
>        pvchange --addtag raid1 /dev/md[01]
>        lvcreate -L100M -i2 vg @raid1
>       instead of 'lvcreate -L100M -i2 vg /dev/md0 /dev/md1'
> 
> However, lvcreate checks the number of PVs based on the number of
> arguments, so it fails even if the number of PVs for the tag is many
> enough.
> 
> The same check is done later in the allocation code.
> So it's safe to remove the checks here.
> 
> A patch to fix this and a reproducer script is attached.

After the fix, 'argc' is no longer used and should be removed
in both _read_stripe_params() and _read_mirror_params().

This is the updated version of the patch.

Thanks,
-- 
Jun'ichi Nomura, NEC Corporation of America
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lvm2-remove-incorrect-check-of-num-pvs.patch
Type: text/x-patch
Size: 2136 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20070913/b3d8ec14/attachment.bin>

      reply	other threads:[~2007-09-13 22:11 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-12 18:19 [LVM2 PATCH] Fix lvcreate's checking of the number of PVs Jun'ichi Nomura
2007-09-13 22:11 ` Jun'ichi Nomura [this message]

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=46E9B5A5.1090209@ce.jp.nec.com \
    --to=j-nomura@ce.jp.nec.com \
    --cc=lvm-devel@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 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.