Find the answer to your Linux question:
Results 1 to 5 of 5
Integration of the new drive Once the defective drive has been removed and the new one installed, it needs to be intagrated into the RAID array. This needs to be ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux User postcd's Avatar
    Join Date
    Apr 2011
    Posts
    350

    How to integrate HDD into raid array after replacement?


    Integration of the new drive
    Once the defective drive has been removed and the new one installed, it needs to be intagrated into the RAID array. This needs to be done for each partition.
    # mdadm /dev/md0 -a /dev/sdb1
    # mdadm /dev/md1 -a /dev/sdb2
    # mdadm /dev/md2 -a /dev/sdb3
    # mdadm /dev/md3 -a /dev/sdb4
    The new drive is now part of the array and will be synchronized. Depending on the size of the partitions this procedure can take some time. The status of the synchronization can be observed using cat /proc/mdstat.
    I have only 2 drives, what exact commands to do after one was replaced as faulty please?
    "Avoid the Gates of Hell. Use Linux affordable VPS."

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,755
    It depends upon the RAID level you used. If just mirroring, then the good drive data should be written automatically to the new drive. If the RAID was striped, then you are probably toast - you have lost as much as 1/2 of your data... In any case, a 2 drive array should NOT allow striping. If it does, then you have only 1/2 of the total storage space - 2x1TB discs == 1TB of data where each drive has adequate parity data to recover the other. I think that 3 is the effective minimum. I use 4 for a RAID, and have had no problems in recovering to the new drive.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  3. #3
    Linux User postcd's Avatar
    Join Date
    Apr 2011
    Posts
    350
    I think there is raid (im not sure which)

    and the disk is: 2x HDD 3,0 TB SATA

    Please which command/s i need to do if there is
    A) raid 1
    B) raid 0
    ?

    // RAID1 HDD replacement tutorial: http://www.howtoforge.com/replacing_..._a_raid1_array
    Last edited by postcd; 04-12-2014 at 10:05 PM.
    "Avoid the Gates of Hell. Use Linux affordable VPS."

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Engineer docbop's Avatar
    Join Date
    Nov 2009
    Location
    Woodshed, CA
    Posts
    949
    If using RAID 0 then you have lost everything, RAID 0 means Zero protection.

    If RAID 1 mirrorset then here's a link to help get started.

    http://www.linuxquestions.org/questi...-drive-736084/
    A lion does not lose sleep, over the opinion of sheep.

  6. #5
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,755
    I never use RAID for my system drive. I do for data however. For the system drive, I make regular backups of the drive, either by taking the system offline and using dd to create a bit image of the drive, or using rsync to backup changed files, or both (preferably). If you DO want RAID for your system drive, then a mirrored configuration is probably your best option. If one drive fails, you can remove it, plug in a new drive of the same size, and it should get copied from the good drive.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •