Re: Upgrading Raid1 array to have 2. disks.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Anders Fugmann wrote:

Sorry if this is the wrong list to post this on.

It's the right list.


I have made an error when creating a new raid1 array as I specified that
the raid should consist of only one disk. Now, I would like to add another disk, but mdadm insists on adding it as a spare disk, offering no data redundancy.

I have read the manpages, and tried googling without success.
I do not wish to destroy the data on the discs, and recreate the array but It might be a last resort. Can anyone help me convince mdadm to add the 2. partition as an active disk.

You could keep your data by doing this:


Remove the current spare:

mdadm --remove /dev/md/0 /dev/ide/host0/bus0/target0/lun0/part1[0]

Create new array with

mdadm --create /dev/md/1 --level=1
--raid-devices=/dev/ide/host0/bus0/target0/lun0/part1[0] missing

Then create fs on new array, mount & copy data to the new array. Stop the old array, add disk from old array to the new array.


-- Mads Peter Bach Systemadministrator, Det Humanistiske Fakultet, Aalborg Universitet Kroghstræde 3 - 5.111, DK-9220 Aalborg Øst - (+45) 96358062 # whois MPB1-DK@whois.dk-hostmaster.dk

-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux