linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Doug Ledford <dledford@redhat.com>
To: Dan Williams <dan.j.williams@intel.com>,
	Linux RAID Mailing List <linux-raid@vger.kernel.org>
Subject: Re: [[Patch mdadm] 1/5] Make the IMSM_DEVNAME_AS_SERIAL option work when creating containers. This allows a person to testing using loopback devices that don't support serial number queries.
Date: Tue, 19 Jan 2010 00:31:56 -0500	[thread overview]
Message-ID: <4B5543CC.3060901@redhat.com> (raw)
In-Reply-To: <e9c3a7c21001182042k1a88e21fpc64ff0bb75ff5854@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 3495 bytes --]

On 01/18/2010 11:42 PM, Dan Williams wrote:
> On Mon, Jan 18, 2010 at 6:55 PM, Doug Ledford <dledford@redhat.com> wrote:
>> On 01/18/2010 05:13 PM, Dan Williams wrote:
>>> Hi Doug,
>>>
>>> On Mon, Jan 11, 2010 at 1:38 PM, Doug Ledford <dledford@redhat.com> wrote:
>>>> Signed-off-by: Doug Ledford <dledford@redhat.com>
>>>> ---
>>>>  super-intel.c |    5 ++++-
>>>>  1 files changed, 4 insertions(+), 1 deletions(-)
>>>>
>>>> diff --git a/super-intel.c b/super-intel.c
>>>> index d6951cc..fcf438c 100644
>>>> --- a/super-intel.c
>>>> +++ b/super-intel.c
>>>> @@ -3208,7 +3208,10 @@ static int add_to_super_imsm(struct supertype *st, mdu_disk_info_t *dk,
>>>>        dd->fd = fd;
>>>>        dd->e = NULL;
>>>>        rv = imsm_read_serial(fd, devname, dd->serial);
>>>> -       if (rv) {
>>>> +       if (rv && check_env("IMSM_DEVNAME_AS_SERIAL")) {
>>>> +               memset(dd->serial, 0, MAX_RAID_SERIAL_LEN);
>>>> +               fd2devname(fd, (char *) dd->serial);
>>>> +       } else if (rv) {
>>>
>>> This just duplicates the check already inside imsm_read_serial().
>>> Containers on loopback devices worked before this patch, so I'll send
>>> a revert.
>>>
>>> --
>>> Dan
>>
>> Me thinks you didn't try it, because this does not duplicate the code in
>> imsm_read_serial().  That code is needed to assemble an IMSM array that
>> already exists on loopback devices.  This is needed to *create* an imsm
>> container on fresh loopback devices.  I'm assuming your imsm container
>> superblocks already existed or some such.
>>
> 
> Me thinks you did not try it either :-)
> 
> # export IMSM_DEVNAME_AS_SERIAL=1
> # mdadm --zero-superblock /dev/loop[0-3]
> # mdadm -Eb /dev/loop[0-4]
> # mdadm -E /dev/loop0
> mdadm: No md superblock detected on /dev/loop0.
> # mdadm --create /dev/md/imsm /dev/loop[0-3] -n 4 -e imsm
> mdadm: /dev/loop0 appears to contain an ext2fs file system
>     size=306816K  mtime=Sat Nov 21 10:54:51 2009
> mdadm: /dev/loop1 appears to contain an ext2fs file system
>     size=306816K  mtime=Sat Nov 21 10:54:51 2009
> mdadm: imsm unable to enumerate platform support
>     array may not be compatible with hardware/firmware
> Continue creating array? y
> mdadm: container /dev/md/imsm prepared.
> # mdadm -Eb /dev/loop[0-3]
> ARRAY metadata=imsm
>    spares=4
> 
> # mdadm -E /dev/loop0
> /dev/loop0:
>           Magic : Intel Raid ISM Cfg Sig.
>         Version : 1.0.00
>     Orig Family : 00000000
>          Family : 697a43ec
>      Generation : 00000001
>            UUID : ffffffff:ffffffff:ffffffff:ffffffff
>        Checksum : c3d8d367 correct
>     MPB Sectors : 1
>           Disks : 1
>    RAID Devices : 0
> 
>   Disk00 Serial : /dev/loop0
>           State : spare
>              Id : 00000000
>     Usable Size : 204382 (99.81 MiB 104.64 MB)
> 
> This is with:
> commit 6acad4811b06335a2602fa1eeaec3a8f47f96591
> Author: Michael Evan <mjevans1983@gmail.com>
> Date:   Wed Dec 9 21:52:18 2009 -0800
> 
> --
> Dan

Ah, OK.  I did say we had been carrying this around in our SRPM for a
while, I just hadn't tried removing it since it was necessary.  I take
it you are implying that that changeset is the one that rendered it no
longer necessary?

-- 
Doug Ledford <dledford@redhat.com>
              GPG KeyID: CFBFF194
	      http://people.redhat.com/dledford

Infiniband specific RPMs available at
	      http://people.redhat.com/dledford/Infiniband


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  reply	other threads:[~2010-01-19  5:31 UTC|newest]

Thread overview: 66+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-11 20:38 Minor mdadm fixes Doug Ledford
2010-01-11 20:38 ` [[Patch mdadm] 1/5] Make the IMSM_DEVNAME_AS_SERIAL option work when creating containers. This allows a person to testing using loopback devices that don't support serial number queries Doug Ledford
2010-01-18 22:01   ` Neil Brown
2010-01-18 22:13   ` Dan Williams
2010-01-19  1:55     ` Doug Ledford
2010-01-19  4:42       ` Dan Williams
2010-01-19  5:31         ` Doug Ledford [this message]
2010-01-19  5:47           ` Dan Williams
2010-01-11 20:38 ` [[Patch mdadm] 2/5] Move the files mdmon opens into /dev/ to support handoff after pivotroot Doug Ledford
2010-01-18 22:09   ` Neil Brown
2010-01-19  7:21     ` Luca Berra
2010-01-19 17:51     ` Doug Ledford
2010-02-01 20:32       ` Bill Davidsen
2010-02-01 21:32         ` Doug Ledford
2010-02-01 22:42           ` Bill Davidsen
2010-02-02  4:08             ` Michael Evans
2010-02-02  7:17               ` Luca Berra
2010-02-02 15:42               ` Bill Davidsen
2010-02-02 18:19                 ` Doug Ledford
2010-02-04 13:50                   ` Bernd Schubert
2010-02-04 15:03                     ` Bernd Schubert
2010-02-04 15:48                       ` Doug Ledford
2010-02-04 16:40                         ` Bernd Schubert
2010-02-04 17:35                           ` Doug Ledford
2010-02-02 18:11               ` Doug Ledford
2010-02-02 18:07             ` Doug Ledford
2010-02-02 18:18               ` Bill Davidsen
2010-02-04  6:40       ` Neil Brown
2010-02-04 18:45         ` Doug Ledford
     [not found]           ` <4B6B15B3.8030205-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2010-02-04 23:04             ` Dan Williams
     [not found]               ` <e9c3a7c21002041504w17565653m5a8b8cd90543cf1e-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-02-05  0:21                 ` Bill Davidsen
2010-02-05 12:14                   ` Luca Berra
2010-02-06 17:51               ` Doug Ledford
     [not found]                 ` <4B6DAC06.6060909-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2010-02-06 21:07                   ` Dan Williams
     [not found]                     ` <e9c3a7c21002061307le6f5d56ked4fa3711bdd2367-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-02-06 21:46                       ` martin f krafft
2010-02-06 22:06                         ` Michael Evans
2010-02-08 15:32                       ` Doug Ledford
2010-02-08 21:38                         ` Neil Brown
2010-02-09  0:20                           ` Michael Evans
     [not found]                           ` <20100209083838.6568cac0-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2010-02-09  2:19                             ` martin f krafft
     [not found]                               ` <20100209021949.GB11780-0owbi4v4jRjYceiJAzDLgeTW4wlIGRCZ@public.gmane.org>
2010-02-09 20:34                                 ` Doug Ledford
     [not found]                                   ` <4B71C6CA.3010407-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2010-02-10  0:58                                     ` Mr. James W. Laferriere
     [not found]                                       ` <alpine.LNX.2.01.1002091553580.10004-pIN9qAC4yfKseEBmXaVrNB5FPEiCeG3sAL8bYrjMMd8@public.gmane.org>
2010-02-10  1:33                                         ` Neil Brown
2010-02-10  9:46                                           ` Harald Hoyer
     [not found]                                           ` <20100210123321.324e5de6-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2010-02-10 15:49                                             ` Dan Williams
2010-02-10 16:06                                               ` Michael Evans
     [not found]                                                 ` <4877c76c1002100806w66e504deg767f6ecc8cc7fa8a-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-02-11  2:30                                                   ` Doug Ledford
2010-02-09 20:30                             ` Doug Ledford
2010-02-08  4:23                   ` Neil Brown
2010-02-07 22:13             ` Hans de Goede
2010-02-07 23:06               ` Neil Brown
2010-02-08  3:45           ` Neil Brown
2010-02-08 16:56             ` Bill Nottingham
2010-01-11 20:38 ` [[Patch mdadm] 3/5] We don't like %02d as a metadata format specifier, it confuses us when we read the output back later Doug Ledford
2010-01-18 22:02   ` Neil Brown
2010-01-11 20:38 ` [[Patch mdadm] 4/5] When using -D --export the UUID is helpful, so print it out Doug Ledford
2010-01-18 22:03   ` Neil Brown
2010-01-11 20:38 ` [[Patch mdadm] 5/5] Fix segfault when the AUTO keyword is used in the config file Doug Ledford
2010-01-18 22:03   ` Neil Brown
2010-01-12  0:49 ` Minor mdadm fixes Mr. James W. Laferriere
2010-01-12  3:10   ` Andre Noll
2010-01-12  3:36     ` Doug Ledford
2010-01-12  4:39       ` Andre Noll
2010-01-12  4:46         ` Doug Ledford
2010-01-12  5:21           ` Andre Noll
2010-01-18 22:05 ` Neil Brown

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=4B5543CC.3060901@redhat.com \
    --to=dledford@redhat.com \
    --cc=dan.j.williams@intel.com \
    --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).