• March 29, 2024, 03:37:09 AM
  • Welcome, Guest
Please login or register.

Login with username, password and session length
Advanced search  

News:

This Forum Beta is ONLY for registered owners of D-Link products in the USA for which we have created boards at this time.

Author Topic: Working with Raid1 - what happens when....  (Read 10092 times)

JasonT

  • Level 1 Member
  • *
  • Posts: 7
Working with Raid1 - what happens when....
« on: March 30, 2008, 09:16:54 PM »

Can someone give a rundown of what happens when I swap drives around that are currently formatted as Raid1.


Remove drive 1 and insert new blank drive in slot 1.

Remove drive 2 and insert new blank drive in slot 2.

Remove drive 1, mount it on another computer, make changes to it, reinsert it into DNS slot 1.

Remove drive 2, mount it on another computer, make changes to it, reinsert it into DNS slot 2.

Remove drive 1, swap with drive 2, and vice-versa.

Remove drive 1 and replace with a new blank drive that is smaller in capacity.


Thanks.
Logged

fordem

  • Level 10 Member
  • *****
  • Posts: 2168
Re: Working with Raid1 - what happens when....
« Reply #1 on: March 31, 2008, 05:06:46 AM »

Let me start by making it absolutely clear - RAID1 is not intended to do anything other than provide disk failure related fault tolerance - and the only time a disk should be removed is to replace it after failure.  You may feel that it can be made to deliver other functionality, but that is not what it was designed to do and you run the risk of data loss and or corruption.

The following assumes that the RAID1 array occupies all the available space on the existing drives - and does not hold true for any other configuration - my tests were done using fw 1.03, the results of similar tests with 1.04 may be different - the RAID on this device is software based and as such entirely dependent on the firmware.

Remove drive 1 and insert new blank drive in slot 1/Remove drive 2 and insert new blank drive in slot 2 - as long as the new drive is large enough, the unit will prompt for a format of the new drive, after which it will synchonize or rebuild the array - any additional space will be formatted as a separate volume.

Remove drive 1, mount it on another computer, make changes to it, reinsert it into DNS slot 1/Remove drive 2, mount it on another computer, make changes to it, reinsert it into DNS slot 2 - I haven't personally tested this, but I don't expect the unit to synchronize the data - if the unit was not powered on whilst the disks were out, it will be unaware that a disk was removed and probably do nothing - if it was powered on and has detected the failed disk, it may attempt to format one of the disks and then synchronize the array, you have no guarantee as to which disk it will select as the "valid" disk, and no way to force the selection - you stand a good chance of losing your data.

Remove drive 1, swap with drive 2, and vice-versa - unit will tell you that the disks are out of sequence and ask you to reinstall them - you may lose data.

Remove drive 1 and replace with a new blank drive that is smaller in capacity - I haven't tested this, I would expect the unit to indicate that this configuration is unusable, either before or after formatting the blank disk.



Logged
RAID1 is for disk redundancy - NOT data backup - don't confuse the two.

JasonT

  • Level 1 Member
  • *
  • Posts: 7
Re: Working with Raid1 - what happens when....
« Reply #2 on: March 31, 2008, 07:37:42 AM »

Very interesting.  It seems to be a very fragile alliance. 

So what is the recommended procedure when you have a typical drive failure...

Leave both drives in the DNS, copy the saved mirrored data over the network to another backup drive, THEN remove and replace damaged drive with new one of same capacity, reformat both drives as Raid1 and restore data across the network?

Is this correct?
Logged

fordem

  • Level 10 Member
  • *****
  • Posts: 2168
Re: Working with Raid1 - what happens when....
« Reply #3 on: March 31, 2008, 08:53:51 AM »

Why do you consider it fragile?

To answer your question - good data processing practise dictates that you already have the data backed up - assuming you are compying with this, all you need to do is power the unit down, replace the failed drive with a new one, power the unit up and follow the prompts - this is in effect the same scenario as the first two of your questions.

If you don't have your data backed up, I would suggest, purely out of an abundance of caution, that you back it up before replacing the failed drive
« Last Edit: March 31, 2008, 08:58:25 AM by fordem »
Logged
RAID1 is for disk redundancy - NOT data backup - don't confuse the two.

JasonT

  • Level 1 Member
  • *
  • Posts: 7
Re: Working with Raid1 - what happens when....
« Reply #4 on: March 31, 2008, 11:32:28 AM »


Remove drive 1, swap with drive 2, and vice-versa - unit will tell you that the disks are out of sequence and ask you to reinstall them - you may lose data.



I guess to me this doesn't sound like a very flexible/robust system that protects against human error.

Anyway, it sounds like a scheduled backup is better for my needs.  Is there a way to convert an existing Raid1 to JBOD so I can just do scheduled backups between the two drives?

Logged

fordem

  • Level 10 Member
  • *****
  • Posts: 2168
Re: Working with Raid1 - what happens when....
« Reply #5 on: March 31, 2008, 03:07:28 PM »

Let me start by making it absolutely clear - RAID1 is not intended to do anything other than provide disk failure related fault tolerance - and the only time a disk should be removed is to replace it after failureYou may feel that it can be made to deliver other functionality, but that is not what it was designed to do and you run the risk of data loss and or corruption.

You'll find that a lot of IT related equipment works well when used as designed - it's when you try to make it do things that it was not designed to do, that you'll experience problems - this is a NAS server - it's designed for you to put disks in it, and then store data on them, if you want something to be swapping media in and out of, then you need to buy a removable media drive.

For what it's worth - you run the risk of losing data if you swap drives around in pretty much every RAID device I've seen, and that includes some very expensive SAN storage arrays - the first thing you learn when dealing with RAID arrays is not to remove drives unless absolutely necessary, and to mark them so you can put them back exactly where you took them from.

For protection against human error, you back your data up - RAID1 is NOT a form of backup - it is specifically intended to provide disk failure related fault tolerance - to reduce (and hopefully) eliminate the possible impact of a disk failure.

If you are running a system with out fault tolerant disks, and there is a disk failure, your system stops functioning until such time as the failed disk can be replaced and the data restored from a back up (if available), if you are running a system with fault tolerant disks and a disk fails, the system should continue to run and depending on it's design may allow you to take corrective action without shutting it down, or may require you to shut it down to take corrective action at some later, hopefully more convenient time - the point here is that the system did not stop functioning when the disk failed, it, so to speak, tolerated the fault.

Before I answer your question on converting RAID1 to JBOD, I'd like to point out something - JBOD - as configured on a DNS-323 - forms a single storage volume, concatenating the two drives, it does not give you two separate drives, and one thing you need to be aware of, is that with concatenated drives, failure of either drive can result in ALL of the stored data being lost - theoretically, only the data stored on the failed disk is gone, and whatever is on the remaining disk should be available, but in reality this has not been my experience.

If you want to convert your RAID1 array to separate volumes open the web admin interface, select TOOLS, RAID -  set the RAID type and allow it to reformat - you will of course lose any data stored on the drives.  You can theoretically avoid the loss of the data by removing one of the drives before reformatting the other, it should be recognized as a separate drive when reinserted after the format - however, consider this - if your original data, and your backup copy are on the same device, what do you do if that device (not the disk, the device itself) fails?

« Last Edit: March 31, 2008, 03:12:58 PM by fordem »
Logged
RAID1 is for disk redundancy - NOT data backup - don't confuse the two.

JasonT

  • Level 1 Member
  • *
  • Posts: 7
Re: Working with Raid1 - what happens when....
« Reply #6 on: March 31, 2008, 03:27:07 PM »

Thanks for your detailed and helpful responses.

To be more specific, I'm thinking of getting a second NAS to backup to.  If I do as you suggest: remove drive 1 or 2 from my current mirror and insert it into a new empty DNS, what's the next step?  Will the new DNS mount the transplanted mirror drive as a standard volume (non-raid)?  Then I would just reformat my original DNS as a standard volume also?  Or do I have this backwards?

Logged

fordem

  • Level 10 Member
  • *****
  • Posts: 2168
Re: Working with Raid1 - what happens when....
« Reply #7 on: March 31, 2008, 07:18:06 PM »

You have it right - if you move one half of a mirrored pair over to a second DNS-323, it should recognize that drive as standard volume and you can then reformat the remaining drive as a standard volume.
Logged
RAID1 is for disk redundancy - NOT data backup - don't confuse the two.

ECF

  • Administrator
  • Level 11 Member
  • *
  • Posts: 2692
Re: Working with Raid1 - what happens when....
« Reply #8 on: April 28, 2008, 04:18:10 PM »

Well put fordem thank you
Logged
Never forget that only dead fish swim with the stream

Spud387

  • Level 1 Member
  • *
  • Posts: 1
Re: Working with Raid1 - what happens when....
« Reply #9 on: September 16, 2008, 03:08:48 PM »

I have a question similar to the OP's.

When loading data to the DNS-323 I am hearing clicking sounds from one of the HDs (from reading about the Seagate 1TB drives online, it could be defective). I want to exchange the drive.

My drives are currently in RAID1. I want to try to determine which drive is making the sounds. Here is my "what will happen scenario?"
I:
Power down the DNS-323
Remove the drive from slot 2
Power up unit
Will the unit be readable and I be able to access the data on the drive in slot 1? Can I write to it?

Then, if possible, what if I:
Write files to the DNS-323 HDD in slot 1 (DNS-323 still missing the secondary HDD at this point)
Power down the DNS-323
Re-add the HDD from slot 2 into slot 2 of the DNS-323 (2nd HDD has not been touched since being removed)
Power up DNS-323
Will the 2nd HDD be formatted to sync with the HDD in slot 1?
« Last Edit: September 16, 2008, 03:10:46 PM by Spud387 »
Logged

ECF

  • Administrator
  • Level 11 Member
  • *
  • Posts: 2692
Re: Working with Raid1 - what happens when....
« Reply #10 on: September 23, 2008, 09:46:23 AM »

Yes. The data you added to the remaining drive will be added to the second drive when put back into the DNS-323 and the sync completes.
Logged
Never forget that only dead fish swim with the stream

fordem

  • Level 10 Member
  • *****
  • Posts: 2168
Re: Working with Raid1 - what happens when....
« Reply #11 on: September 23, 2008, 01:18:37 PM »

I have a question similar to the OP's.

When loading data to the DNS-323 I am hearing clicking sounds from one of the HDs (from reading about the Seagate 1TB drives online, it could be defective). I want to exchange the drive.

My drives are currently in RAID1. I want to try to determine which drive is making the sounds. Here is my "what will happen scenario?"
I:
Power down the DNS-323
Remove the drive from slot 2
Power up unit
Will the unit be readable and I be able to access the data on the drive in slot 1? Can I write to it?

What will happen depends on whether you have a defective drive or not, and which drive is defective.

You could find, if the drive in slot 1 is defective that when you remove the drive in slot 2, you no longer have access to your data.


Quote
Then, if possible, what if I:
Write files to the DNS-323 HDD in slot 1 (DNS-323 still missing the secondary HDD at this point)
Power down the DNS-323
Re-add the HDD from slot 2 into slot 2 of the DNS-323 (2nd HDD has not been touched since being removed)
Power up DNS-323
Will the 2nd HDD be formatted to sync with the HDD in slot 1?

Not necessarily - if the drive still has the partions on it, the DNS-323 may or may not recognise the need to resync, it may or may not prompt you to format the drive and if you accept the prompt it may or may not format the drive it says it's going to format.

I would STRONGLY SUGGEST that you backup your data before removing any disks from the DNS-323
Logged
RAID1 is for disk redundancy - NOT data backup - don't confuse the two.

bspvette86

  • Guest
Re: Working with Raid1 - what happens when....
« Reply #12 on: September 23, 2008, 04:20:00 PM »

I gotta agree with Fordem on this one.  Always backup your data first before making any changes.  Especially when dealing with the DNS-323.  I have seen mine format the opposite disk from what it told me and then had to do a full restore.

Regards,
BV
Logged