* Strange raid device numbering
@ 2010-10-07 23:43 J.A. Magallón
2010-10-08 12:03 ` Phil Turmel
0 siblings, 1 reply; 2+ messages in thread
From: J.A. Magallón @ 2010-10-07 23:43 UTC (permalink / raw)
To: Linux Kernel
Hi...
I'm running kernel 2.6.36-rc6.
I have just built a simple raid0 array with two disks, and I followed what I
had always done:
raid=/dev/md0
ndisk=2
disks="/dev/sda1 /dev/sdb1"
block=4
chunk=256
stride=$((chunk/block))
stripe=$((stride*ndisk))
for i in $disks
do
mdadm --zero-superblock --force $i
done
mdadm -C -f -v $raid --level=0 --chunk=$chunk -n $ndisk $disks
sleep 5
mdadm -S $raid
mdadm --assemble $raid $disks
mkfs.ext4 -b $((block*1024)) -E stride=$stride,stripe-width=$stripe $raid
Strangely, after I reboot, the system insists in numbering it as
md127, instead of md0.
Why ?
How can I force it to be md0 ? (its half aesthetics, half curiosity...)
TIA
--
J.A. Magallon <jamagallon()ono!com> \ Software is like sex:
\ It's better when it's free
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: Strange raid device numbering
2010-10-07 23:43 Strange raid device numbering J.A. Magallón
@ 2010-10-08 12:03 ` Phil Turmel
0 siblings, 0 replies; 2+ messages in thread
From: Phil Turmel @ 2010-10-08 12:03 UTC (permalink / raw)
To: "J.A. Magallón"; +Cc: Linux Kernel
Hi J.A.,
On 10/07/2010 07:43 PM, J.A. Magallón wrote:
> Hi...
>
> I'm running kernel 2.6.36-rc6.
> I have just built a simple raid0 array with two disks, and I followed what I
> had always done:
[snip /]
> Strangely, after I reboot, the system insists in numbering it as
> md127, instead of md0.
>
> Why ?
> How can I force it to be md0 ? (its half aesthetics, half curiosity...)
I'm gonna guess that you have some combination of an initramfs, and/or you
don't have an /etc/mdadm.conf, and/or you haven't updated your initramfs with
the latest copy of it.
Raid auto-assembly in the kernel uses the minor numbers in the superblock (if
it can). Assembly by mdadm without instructions from mdadm.conf uses minor
numbers from 127 and down. (This may have changed in mdadm in the last few
months, but I recently switched from kernel auto-assembly to initramfs
assembly, so I can't say for sure.)
I've chosen to *not* use mdadm.conf, and find all of my devices with "LABEL="
syntax.
HTH,
Phil
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-10-08 12:03 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-07 23:43 Strange raid device numbering J.A. Magallón
2010-10-08 12:03 ` Phil Turmel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox