From: NeilBrown <neilb@suse.de>
To: Lukasz Orlowski <lukasz.orlowski@intel.com>
Cc: linux-raid@vger.kernel.org
Subject: Re: [PATCH 3/3] Create: Incorrect message when creating a volume with explicit md dev name
Date: Wed, 21 Sep 2011 13:48:20 +1000 [thread overview]
Message-ID: <20110921134820.24593401@notabene.brown> (raw)
In-Reply-To: <20110919165245.9239.28871.stgit@gklab-128-192.igk.intel.com>
[-- Attachment #1: Type: text/plain, Size: 3003 bytes --]
On Mon, 19 Sep 2011 18:52:45 +0200 Lukasz Orlowski
<lukasz.orlowski@intel.com> wrote:
> Appears when one attempts to create RAID 1 volume on 2 disks within a
> container with an existing RAID 5 volume on 3 disks and specifies the
> md device explicitly (e.g. /dev/md127). Instead of saying that such volume
> cannot be created it says that the devices have insufficient size.
I cannot reproduce this and I don't really understand what problem you are
trying to solve (seems to be happening a lot today :-( )
Could you give me a simple list of commands that produce undesirable results?
Thanks,
NeilBrown
>
> Signed-off-by: Lukasz Orlowski <lukasz.orlowski@intel.com>
> ---
> Create.c | 8 ++++++--
> super-intel.c | 10 +++++++---
> 2 files changed, 13 insertions(+), 5 deletions(-)
>
> diff --git a/Create.c b/Create.c
> index 47e5fc8..baadd9f 100644
> --- a/Create.c
> +++ b/Create.c
> @@ -262,9 +262,13 @@ int Create(struct supertype *st, char *mddev,
> if (size && chunk && chunk != UnSet)
> size &= ~(unsigned long long)(chunk - 1);
> newsize = size * 2;
> - if (st && ! st->ss->validate_geometry(st, level, layout, raiddisks,
> - &chunk, size*2, NULL, &newsize, verbose>=0))
> + if (st && !
> + st->ss->validate_geometry(
> + st, level, layout, raiddisks, &chunk,
> + size*2, NULL, &newsize, verbose >= 0)) {
> + fprintf(stderr, Name ": create aborted.\n");
> return 1;
> + }
>
> if (chunk && chunk != UnSet) {
> newsize &= ~(unsigned long long)(chunk*2 - 1);
> diff --git a/super-intel.c b/super-intel.c
> index 616853b..51874ae 100644
> --- a/super-intel.c
> +++ b/super-intel.c
> @@ -5223,9 +5223,13 @@ static int reserve_space(struct supertype *st, int raiddisks,
> /* chunk is in K */
> minsize = chunk * 2;
>
> - if (cnt < raiddisks ||
> - (super->orom && used && used != raiddisks) ||
> - maxsize < minsize ||
> + if (cnt < raiddisks || (super->orom && used && used != raiddisks)) {
> + fprintf(stderr, Name ": the option-rom requires all "
> + "member disks to be a member of all volumes.\n");
> + return 0;
> + }
> +
> + if (maxsize < minsize ||
> maxsize == 0) {
> fprintf(stderr, Name ": not enough devices with space to create array.\n");
> return 0; /* No enough free spaces large enough */
>
> ---------------------------------------------------------------------
> Intel Technology Poland sp. z o.o.
> z siedziba w Gdansku
> ul. Slowackiego 173
> 80-298 Gdansk
>
> Sad Rejonowy Gdansk Polnoc w Gdansku,
> VII Wydzial Gospodarczy Krajowego Rejestru Sadowego,
> numer KRS 101882
>
> NIP 957-07-52-316
> Kapital zakladowy 200.000 zl
>
> This e-mail and any attachments may contain confidential material for
> the sole use of the intended recipient(s). Any review or distribution
> by others is strictly prohibited. If you are not the intended
> recipient, please contact the sender and delete all copies.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 190 bytes --]
prev parent reply other threads:[~2011-09-21 3:48 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-19 16:52 [PATCH 0/3] Series short description Lukasz Orlowski
2011-09-19 16:52 ` [PATCH 1/3] Create: Allow to create two volumes of different sizes within one container Lukasz Orlowski
2011-09-21 3:31 ` NeilBrown
2011-09-21 6:31 ` Dan Williams
2011-09-21 6:55 ` NeilBrown
2011-12-14 18:15 ` Dan Williams
2011-09-19 16:52 ` [PATCH 2/3] Create: Unnecessary prompt about device being busy Lukasz Orlowski
2011-09-21 3:36 ` NeilBrown
2011-09-19 16:52 ` [PATCH 3/3] Create: Incorrect message when creating a volume with explicit md dev name Lukasz Orlowski
2011-09-21 3:48 ` NeilBrown [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=20110921134820.24593401@notabene.brown \
--to=neilb@suse.de \
--cc=linux-raid@vger.kernel.org \
--cc=lukasz.orlowski@intel.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).