linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andreas Haumer <andreas@xss.co.at>
To: linux-raid@vger.kernel.org
Subject: mdadm 2.1: command line option parsing bug?
Date: Fri, 18 Nov 2005 20:34:14 +0100	[thread overview]
Message-ID: <437E2CB6.2030903@xss.co.at> (raw)

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

Hi!

I just upgraded to mdadm-2.1 from mdadm-1.12.0 and noticed
that the following command (which is even mentioned in the
manual page) doesn't work anymore:

root@tolstoi:~ {838} $ mdadm -Ebsc partitions
mdadm: cannot open partitions: No such file or directory


(I always use this command to create my mdadm.conf file,
so I found the problem very quickly after upgrading ;-)

After playing a little bit with the available commandline
options I found that the following commands do work:

root@tolstoi:~ {839} $ mdadm -Eb -sc partitions
ARRAY /dev/md/1 level=raid1 num-devices=3 UUID=c2c22b31:909b7973:0e4224bb:19cf529d

ARRAY /dev/md/0 level=raid5 num-devices=3 UUID=7abbd703:643ffe8e:d6ae4d0e:1b0908aa

as well as the following variations:

root@tolstoi:~ {840} $ mdadm -Eb -s -c partitions
ARRAY /dev/md/1 level=raid1 num-devices=3 UUID=c2c22b31:909b7973:0e4224bb:19cf529d

ARRAY /dev/md/0 level=raid5 num-devices=3 UUID=7abbd703:643ffe8e:d6ae4d0e:1b0908aa


root@tolstoi:~ {841} $ mdadm --examine --brief --scan --config=partitions
ARRAY /dev/md/1 level=raid1 num-devices=3 UUID=c2c22b31:909b7973:0e4224bb:19cf529d

ARRAY /dev/md/0 level=raid5 num-devices=3 UUID=7abbd703:643ffe8e:d6ae4d0e:1b0908aa


So it looks like the commandline option parsing algorithm
in mdadm.c (which is way too complicated for me to find out
quickly what is going wrong here... ;-) has some problem with
the "-Ebsc partitions" variant.

Seems to be a bug?

I also noticed that there is now an additional newline between
the "ARRAY" lines. Is that intentional? IMHO there should only
by one newline after each line here.

HTH

- - andreas

- --
Andreas Haumer                     | mailto:andreas@xss.co.at
*x Software + Systeme              | http://www.xss.co.at/
Karmarschgasse 51/2/20             | Tel: +43-1-6060114-0
A-1100 Vienna, Austria             | Fax: +43-1-6060114-71
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDfiy0xJmyeGcXPhERAp9KAKCfQru5tViXFM3I+MGwEfTfSS7zwACgxD0C
ExjRVCIUb3ik5x1zCFYslFo=
=Rc7n
-----END PGP SIGNATURE-----

             reply	other threads:[~2005-11-18 19:34 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-18 19:34 Andreas Haumer [this message]
2005-11-21 23:21 ` mdadm 2.1: command line option parsing bug? Neil Brown
2005-11-22 11:21   ` Michael Tokarev
2005-11-24  5:15     ` Neil Brown
2005-11-22 15:41   ` Molle Bestefich
2005-11-24  5:25     ` Neil Brown
2005-11-24  7:31       ` Ross Vandegrift
2005-12-15  1:53       ` Molle Bestefich
2005-12-15  4:19         ` Neil Brown
2005-12-15 10:37           ` Molle Bestefich
2005-11-22 22:05   ` Andre Noll
2005-11-26 14:04     ` RAID0 performance question JaniD++
2005-11-26 15:56       ` Raz Ben-Jehuda(caro)
2005-11-26 16:08         ` JaniD++
2005-11-26 17:11           ` Lajber Zoltan
2005-11-26 17:34             ` JaniD++
2005-11-26 19:47               ` Lajber Zoltan
2005-11-26 23:27       ` Neil Brown
2005-11-26 23:37         ` JaniD++
2005-11-27 15:39         ` Al Boldi
2005-11-27 16:21           ` JaniD++
2005-11-27 17:40             ` Al Boldi
2005-11-27 19:02               ` JaniD++
2005-11-30 23:13               ` JaniD++
2005-12-02 19:53                 ` Al Boldi
2005-12-18  0:13                   ` JaniD++
2005-12-19 11:16                     ` Al Boldi
2005-11-22  1:14                       ` JaniD++
2005-11-23 10:48                       ` JaniD++
2005-12-21  1:40                     ` Neil Brown
2005-11-22  1:56                       ` JaniD++
2005-12-22  4:49                         ` Neil Brown
2005-11-23  9:44                           ` JaniD++

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=437E2CB6.2030903@xss.co.at \
    --to=andreas@xss.co.at \
    --cc=linux-raid@vger.kernel.org \
    /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).