You are not logged in.

#1 2008-05-02 02:31:27

QuimaxW
Member
From: Papua New Guinea
Registered: 2006-12-03
Posts: 228
Website

Move RAID drives

I've been googling for two days and haven't found anything.

My current setup is:
/ = /dev/sda (Pata - Master channel 1)
/dev/md0 = sdb1, sdc1, sdd1, & sde1 - All are SATA drives.

My problem is that I'm being cheap. My (freshed downgraded to) PIII-667MHz server can't deal with the RAID 5 demands I'm putting on it. To relieve that, I want to install a 200GB PATA drive (that I already own) on the master slave spot. My issue is that doing this will move the raid drive to sdc,d,e,&f, break the raid and force me to add the former sdb as a new drive.

Is there a way I can do this without having the RAID rebuild itself?


"He is no fool who gives what he cannot keep to gain that which he cannot lose." -Jim Elliot

Offline

#2 2008-05-02 10:24:50

SomeGuy1337
Member
Registered: 2007-08-18
Posts: 32

Re: Move RAID drives

You can reassemble the array specifying what ever devices you want, or better yet you can references the devices with this UUID string which im not sure what stands for... but they seem unique and unchanging (at least for me!)

[someguy@z0r ~]$ sudo mdadm --detail --scan
ARRAY /dev/md0 level=raid1 num-devices=2 UUID=1e833dfe:7facd791:e140cea1:663084df

if u append the output of that command to /etc/mdadm.conf it should automagicaly assemble the array on start up regardless off device names

the thing wont (shouldnt) attempt to reassemble an array unless its valid
see mdadm --assemble --help

and finally you could jsut change the device files with udev configuration

Offline

#3 2008-05-06 02:38:26

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,224
Website

Re: Move RAID drives

SomeGuy1337 wrote:

You can reassemble the array specifying what ever devices you want, or better yet you can references the devices with this UUID string which im not sure what stands for... but they seem unique and unchanging (at least for me!)

That would be my suggestion smile

And yes, UUID is always unique and unchanging for a given device:

A Universally Unique Identifier is an identifier standard used in software construction, standardized by the Open Software Foundation (OSF) as part of the Distributed Computing Environment (DCE). The intent of UUIDs is to enable distributed systems to uniquely identify information without significant central coordination. Thus, anyone can create a UUID and use it to identify something with reasonable confidence that the identifier will never be unintentionally used by anyone for anything else. Information labeled with UUIDs can therefore be later combined into a single database without needing to resolve name conflicts.

http://en.wikipedia.org/wiki/UUID

Offline

Board footer

Powered by FluxBB