Showing posts with label RAID5. Show all posts
Showing posts with label RAID5. Show all posts

Wednesday, May 23, 2012

Windows 7: Considering a RAID Array for Performance

It had been more than a year since I had last looked at adding a RAID array to improve performance.  I could see that my hard drive light was on very often, and the system slowed way down when that happened.  So it seemed advisable to take another shot at RAID.

I had a reasonably good backup arrangement.  As such, I wasn't too worried about the risk of losing data.  My motherboard would accommodate RAID 5 or 10, if I wanted to add more drives, but at this point hard drive supplies were still reeling from the floods in Thailand.  Prices were high on HDDs, and large solid-state devices (SSDs) were still prohibitively expensive.  For at least the near future, I was looking at a two-drive RAID 0.

The main problem with RAID 0 would be the amount of time required to restore my data from backup, and the increased likelihood that I would have to do so (because, in RAID 0, failure of either drive would mean failure of the entire array).  It made sense to make the RAID array as small as possible.  It would need to contain data that I used frequently, but there were a number of other things, less frequently accessed, that I could put onto a third drive that would not be part of the array.  A smaller RAID array would be quicker to restore and would also require smaller, less expensive drives -- which, in turn, would make it more feasible, sometime down the line, to add more drives and switch to a different RAID flavor.

The Moo0 System Monitor was informing me that, at present, my hard drive delays were coming from my existing data drive, not from drive C.  I had not been eager to reinstall Windows onto a new RAIDed drive C.  I was also not too keen on the prospect that Acronis backups and restores involving a RAIDed drive C could be complicated.  So there seemed to be some reason to put my programs partition (drive C) onto that standalone third drive as well.

While I was content with my backup arrangement on a day-to-day basis, I did not presently have an hourly backup.  If I decided to make that third drive a large one, I could use some of its space to store hourly backups.

The plan, then, was for the third drive to contain my drive C partition, my large and infrequently used data items, and perhaps an hourly backup partition.  It could also hold the partition where I stored my Acronis drive images, the partition containing my customized Start Menu and installation-related programs, and the partition that I used for various programs' cache folders and such.  The only partitions on this third drive that would need to be backed up would be drive C, the data partition, and the Start Menu partition.
At this point, there was a pause.  I found myself involved with a large spreadsheet task that was just dragging in its calculations. Those calculations were taking so long that I was forced to take considerable breaks from the project to do other things while Excel would grind away. The problem there was that, when I did come back to the spreadsheet, sometimes it would be several hours later. By that point, my head was no longer tuned in to the project; I was thinking about other things. As a result, I was forgetting and overlooking things that I would have handled much more efficiently if the computer had been able to keep up.

So before installing the RAID array, I upgraded my CPU.  To my surprise, although Moo0 had not seemed to indicate this, the faster CPU contributed noticeably to other tasks as well.  This performance boost took away some of the urgency behind the transition to RAID.

A second hardware upgrade made an even greater difference.  I had found that sometimes I would have to wait quite a while for the screen to keep up when I would switch from one program to another.  I had assumed that the hard drive was the reason.  As I could see from its activity light, it was keeping very busy, and Moo0 was indicating that it was the bottleneck.  Still, it occurred to me that some of the display issues might be due to limits in the motherboard's onboard graphics.  So I installed a 2GB video card.  Suddenly things were *much* better.  It seemed that the hard drive may somehow have been working overtime to compensate for inadequate video.

The speedup wrought by these two upgrades -- the faster CPU and the more capacious video card -- was so substantial as to eliminate, for now, the need for a RAID array.  In that sense, these other hardware upgrades paid for themselves.  I was pleased not to have to spend the time and endure the upheaval that would be involved in getting my data onto a RAID array, as well as the more-than-doubled risk that a single hard drive failure would wipe out all (not just some) of my data.

There were two other considerations favoring my decision to delay the RAID investment until a time of greater need.  First, as I could see, solid state drives (SSDs) were coming down in price.  Second, I was doing some housecleaning, deleting or compressing some materials and putting others onto separate partitions.  It seemed possible that, at some point, an SSD (or, conceivably, an SSD RAID array) containing a smaller set of files would be much more affordable.  Hence, for now, the RAID investment was once again on the back burner.

Thursday, January 6, 2011

Windows 7: Setting Up RAID

The two potential advantages of setting up hard drives in a RAID array seemed to be performance and/or safety.  Among the many types of RAID arrays, some of the more frequently mentioned were RAID 0, RAID 1, and RAID 5.

RAID 0 used a "striping" approach where data was divided between hard drives.  This was intended to speed up data reading.  The drawback was that failure of either drive would mean loss of all data, since the data was stored on the drives in a puzzle-like form that could not be reconstructed without all of the pieces from both drives.  If someone had a RAID 0 array containing 100 drives, and if the whole array would fail as soon as any one drive failed, the safety of the whole array would be only as great as the safety of its weakest drive.  So the performance improvements of RAID 0 meant greater risk of data loss.

RAID 1 used a mirroring approach where everything was written onto disk 1, but simultaneously copied to disk 2.  This would not speed things up at all; if anything, it would slow things down a bit, as the system coped with twice as much data.  The purpose of RAID 1 was safety.  Either drive could fail, and yet no data would be lost.  If the computer was set up so as to let the user know that a drive had failed, then s/he could just replace the failed drive and let the RAID array fill in the new replacement with the current state of the data.

RAID 5 used a striping approach, for speed, combined with a distribution scheme for safety.   A RAID 5 array would have at least three drives.  Failure of one drive would reduce performance but would not result in data loss.

As of this writing, Microsoft was not providing clear information regarding which versions of Windows 7 offered which kinds of RAID.  Informal reports indicated that only RAID0 and RAID1 were available in user versions of Win7, and that RAID5 (and perhaps other kinds) were available in server versions of Win7.  Acronis said that RAID5 was available only in Windows Server 2000, 2003, and 2008.  The approach I planned to take, then, was to set up a RAID0 array with good backup.

To set up the array, I typed diskmgmt.msc in the Start button > Search programs and files box.  That opened up Disk Management.  The disks I wanted to put into my array were Disk 0 and Disk 1.  First, I wanted to set up a 50GB array called PROGRAMS to contain Windows program files.  I right-clicked on the gray part of the Disk Management window where it said "Disk 0" and chose "New striped volume."  This opened the New Striped Volume Wizard.  I added Disk 0 and Disk 1 to the Selected box, specified 25600MB space (on each drive, for a total of 50GB).  I looked into allocation unit size briefly and decided to stick with the default.  As I had gathered elsewhere, I didn't have to worry about the question of converting the disks from basic to dynamic because that was unavoidable with striping, and now I was at the point where the wizard was going to take care of it.

There were some other things I wanted to put into RAID0 arrays for speed.  Examples included virtual machines and files on which I would be doing video editing.  I set up arrays for those.  But there were also some things that I didn't want to put into a RAID0 array.  These were items that were big and bulky, and therefore would take a lot of time to back up, but were not performance-intensive.  General-purpose storage would fall into this category.  If I wanted performance in that area, I could move those items out of storage and into a RAID0 workspace.  For storage, I considered using a spanned volume that would put half of the data on each of the two hard drives, so as to reduce the amount of data that I would have to restore if either drive did fail.  But it sounded like restoring data from a spanned volume could be tricky, so I thought I might just divide the stored data into two separate partitions, one on each disk.  To do that, I used the "New simple volume" option in Disk Management.

There didn't seem to be any point in trying to set up a RAID volume for an Ubuntu dual-boot.  This was software RAID, governed by the Windows operating system.  Windows allowed the user to allocate only part of a drive to RAID, and as far as I knew Ubuntu set aside whole disks in a hardware RAID array.  I did set aside some space for Ubuntu program installation, however.

With the partitions set up, the next goal was to restore my Windows 7 installation to the PROGRAMS array.  That became a whole ordeal in itself, as described in a separate post.