[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: RAID support for Sun disktype [FIXEDPATCH]
From: |
Jim Meyering |
Subject: |
Re: RAID support for Sun disktype [FIXEDPATCH] |
Date: |
Sun, 21 Dec 2008 17:21:12 +0100 |
"Tom \"spot\" Callaway" <address@hidden> wrote:
> On Sun, 2008-12-21 at 09:33 +0100, Jim Meyering wrote:
>> "Tom \"spot\" Callaway" <address@hidden> wrote:
>> > Attached is a patch to enable RAID support for Sun disks. Aurora SPARC
>> > Linux has been using this successfully for some time now.
>>
>> Thanks for the patch!
>> Can you provide examples that we could massage into
>> a test case or two that would exercise this new code
>> and help prevent accidental regressions later on?
>>
>> I.e., can you give a quick recipe for creating an image that
>> parted currently fails to recognize as sun-RAID-enabled,
>> yet that _is_ recognized with your patch? Also, since this
>> copies from old-sun to new-sun formats, a stand-alone example
>> showing how to exercise that code would be most welcome.
>>
>> Of course, we can figure out how to do all of this ourselves,
>> but that takes more time... With a clear/concise reproducer/demo
>> I can usually manage to find time to write portable shell code
>> that can serve as an addition to the test suite.
>
> Hmm. Well, anaconda (Aurora's installer, taken from Fedora) won't even
> attempt to do raid ops via parted without this patch present. It just
> kicks back that there is a missing flag. With this patch applied, we're
> able to create and use RAID1.
>
> I'm not sure what sort of test case would apply here, as there really
> isn't much "new" code. I'm not sure how Solaris handles software RAID,
> so that might be an additional fly in the ointment.
Here's what I would have liked to see:
Create a "sun" partition table in a file named "k":
$ dev=k
$ dd if=/dev/null of=$dev bs=1 seek=10M 2> /dev/null
$ parted/parted -s $dev mklabel sun
Create a single partition (something to give the "raid" flag, below):
$ parted/parted -s $dev unit s mkpart ext2 0s 50s
$ parted/parted -m -s $dev unit s p
BYT;
/f/k:10.5MB:file:512:512:sun:;
1:0.00B:26.1kB:26.1kB:::;
Before, setting the "raid" flag would fail:
$ parted/parted -s $dev set 1 raid on
parted/parted: invalid token: raid
With your patch, it succeeds:
$ parted/parted -s $dev set 1 raid on
and parted's print command shows the attribute:
$ parted/parted -m -s $dev unit s p
BYT;
/f/k:20480s:file:512:512:sun:;
1:0s:50s:51s:::raid;
Now that I've done the above, it should be easy to make
that into a test case, since there are already several
very similar ones (see tests/t*).
Would you like to do that?
- RAID support for Sun disktype [FIXEDPATCH], Tom \"spot\" Callaway, 2008/12/13
- Re: RAID support for Sun disktype [FIXEDPATCH], Jim Meyering, 2008/12/21
- Re: RAID support for Sun disktype [FIXEDPATCH], Tom \"spot\" Callaway, 2008/12/21
- Re: RAID support for Sun disktype [FIXEDPATCH],
Jim Meyering <=
- Re: RAID support for Sun disktype [FIXEDPATCH], Tom \"spot\" Callaway, 2008/12/21
- Re: RAID support for Sun disktype [FIXEDPATCH], Jim Meyering, 2008/12/21
- Re: RAID support for Sun disktype [FIXEDPATCH], Tom \"spot\" Callaway, 2008/12/22
- Re: RAID support for Sun disktype [FIXEDPATCH], Jim Meyering, 2008/12/22
- Re: RAID support for Sun disktype [FIXEDPATCH], Tom \"spot\" Callaway, 2008/12/22
- Re: RAID support for Sun disktype [FIXEDPATCH], Jim Meyering, 2008/12/23