3

I'm in need to upgrade my MySQL machine, as currently I am running 2x SATA 7200rpm drives in RAID0. This of course is quite dangerous incase one of the drives fails.

As I do not need too much storage (all my db's together are about 20 - 25gb), I have been thinking about getting 2 SSD's (80 or 120gb) and putting them in RAID1 setup, so incase one of the SSD's fails, there is a backup present.

Price wise, I can also go for a RAID10 setup with 4x SATA drives. But I think 2 SSD's in RAID1 will still perform better.

For a heavily used MySQL machine, do you think the latest generation SSD's are reliable enough yet? And would this be a recommendable setup?

Mr.Boon
  • 1,441
  • 4
  • 24
  • 41
  • Did you read http://serverfault.com/questions/254660/mysql-disk-i-o-and-ssd-drives? – 3molo Jun 27 '11 at 11:12
  • 1
    SSD's will inevitably fail due to write/erase cycle exhaustion. So in RAID1 setup, they'd theoretically fail at exactly the same moment. – Berzemus Jun 27 '11 at 11:14
  • 2
    Wouldn't that hold true for any raid level then? – 3molo Jun 27 '11 at 11:22
  • @Berzemus In theory yes; however, that is the anticipated failure. There could still be other faults where the mirror would be useful. – Daniel B. Jun 27 '11 at 12:46
  • My database has quite a lot of writes/deletes going on. At least 70+ writes per second to the database. Running this 24/7/365 do you think SSD's are not the way to go? I can only afford the Intel X25-M series. – Mr.Boon Jun 27 '11 at 14:19
  • Regarding your disk usage ... a write and a delete aren't the same thing (unless you're over-writing with zeros.) A delete just removes a reference in the file system, so it's significantly less abusive on the hardware than actually changing bits around. – Daniel B. Jun 27 '11 at 15:06
  • On to the math fun: http://download.intel.com/design/flash/nand/mainstream/Specification322296.pdf Intel cites 8.6k IOPS for sustained 4k writes. They claim a minimum 5 year life cycle, so using the same method as Anand ... 8600 4k IOPS = 34400 KB written/sec. 157,680,000 secs in a year * 34400 = roughly 5 PB in writes over 5 years. – Daniel B. Jun 27 '11 at 16:10
  • http://www.intel.com/design/flash/NAND/mainstream/pdf/322697.pdf cites 11.25 TB "Write endurance." I'm not sure how that adds up as far as actual longevity, I'll keep poking around. – Daniel B. Jun 27 '11 at 16:19
  • I *think* that that's 11.25 TB of writes per block before that block is rendered unreliable, but I'm having trouble verifying. You should be good with the 5 PB figure. Little bit of number crunching ... about 34 MB/sec over 5 years or 170 MB/sec over 1 year would kill it(remember that's write, not reading or changing pointers around) – Daniel B. Jun 27 '11 at 18:37

1 Answers1

1

That depends on the environment, and the disks you use. You're probably wanting to look at "Enterprise Flash Drives" rather than SSD. I would make the distinction as the longevity difference is significant.

This article discusses viability of EFDs in enterprise environments. This one discusses longevity of Seagate's "Pulsar" drive. According to Anandt's math, the 200TB version offers about 6 TB of writes before it fails, assuing 4k random read/write over 5 years. The smaller drives add up to less.

You may wish to check the comment string on Chopper 3's post in this question, he has a real world example that may be pertinent to you.

The long and short of it is that it depends on just how write-heavy your environment is. Remember that the wear on SSD/EFD drives is from writes not reads, so if people are just reading from your database, You could conceivably get 2-5 years out of your RAID.

You will get very good performance out of the raid. Switching from spinning disk to SSD has been the single most noticeable performance change in my home PC in the past two years.

Daniel B.
  • 725
  • 7
  • 16
  • I should also point out that RAID 1 is *not* a backup solution. It's a nice failsafe which will help you keep your system running through a single disk failure, but you should have a real backup (offsite is good but at least outside the server) to protect you from a catastrophic failure. – Daniel B. Jun 27 '11 at 13:53
  • Is TRIM possible/necessary/favorable in RAID1? – alfish Aug 09 '11 at 23:25
  • It would certainly increase the longevity of your drives. As far as being possible, depends on your OS and drivers. It wouldn't be absolutely necessary: it'll run without it, but if the option were there I would use it. – Daniel B. Aug 28 '11 at 15:28