What would be the optimal disk config for SQL Server 2008 R2?

I about the same config - you can find some answers here: 1 logical drive vs 2 logical drivers on 1 raid controller to separate data from log files?


I know this is an old question but it's still relevant.

First, some notes on performance. As you mention, there are three "pieces": data files, log files, and tempdb.

1) data files: generally random I/O. If it's a read-heavy workload, RAID 5 is an okay choice. If there are significant writes, then favor RAID 1+0

2) log files: generally sequential writes. RAID 1+0 is optimal, but probably overkill given your constraints, which I'll shortly get to. It is best to separate them for performance and safety reasons(http://support.microsoft.com/kb/2033523/en-us)

3) tempdb: often a significant bottleneck, and requires lots of random read/writes. Does not need to be "safe" because SQL recreates it on startup.

One option, as you did use, is to set up two sets of RAID 1+0. Data files can go on one, log files and OS can go on the other. Whether tempdb is better put on the first or the second depends on your workload. If write-heavy, then put it with the data (so the log files don't get bottlenecked), but if the log files are not a concern then tempdb is better put with them.

This would also be a safe option because many drives need to fail for you to lose data.

Another option would be RAID 1 for the log files (2 disks). Then you can use RAID 1+0 / RAID 5 for the data files (3-4 disks). You can then dedicate the other disks to tempdb. You don't need to use RAID 0, you can just create multiple files for tempdb and assign one to each disk.

If you want to add a hot standby, you're in a tricky spot because of the number of drives: RAID 1+0 requires an even number. Note that RAID 5 has a bit of a risk of data loss during the rebuild because it's a lengthy process and because you need to calculate the parity.

EDIT I did some more reading, and RAID 5 is not really recommended anymore - it's not really that safe because of the rebuild. RAID 1+0 is really the way to go. See, for example: http://en.community.dell.com/dell-groups/dtcmedia/m/mediagallery/19861480/download.aspx (pp. 9-10 in the PDF). One (of several) sources: http://www.reddit.com/r/sysadmin/comments/ydi6i/dell_raid_5_is_no_longer_recommended_for_any/.

Universal notes

  1. keep your log files from getting fragmented. Make sure you size them reasonably with a large auto-growth factor
    http://www.sqlskills.com/blogs/kimberly/8-steps-to-better-transaction-log-throughput/

  2. make sure your partitions are aligned properly.

There are two correlations which when satisfied are a fundamental precondition for optimal disk I/O performance. The results of the following calculations must result in an integer value:

Partition_Offset ÷ Stripe_Unit_Size

Stripe_Unit_Size ÷ File_Allocation_Unit_Size
http://technet.microsoft.com/en-us/library/dd758814(v=sql.100).aspx

  1. if possible, set your cluster sizes to 64 KB