我绝对同意,最大的好处来自增加innodb_db_bufferpool的大小,但是不幸的是,这完全取决于您的数据集的大小以及访问不同磁盘块的频率。我维护着几个很大的数据库,它们的大小都超过200 GB,因此将所有内容都放入RAM并不是真正的选择,因此我们最近切换到了基于SSD的存储。我已经在有关可访问的不同RAID阵列上用于MySQL的IOPS方面进行了大量研究。结果如下:
1,253 IOPS-4 x SCSI 15k(3.5“)磁盘
测试:(g = 0):rw = randrw,bs = 4K-4K / 4K-4K-4K / 4K-4K,ioengine = libaio,iodepth = 64读取:io = 3071.7MB,bw = 5012.8KB / s,iops = 1253 ,runt = 627475msec写入:io = 1024.4MB,bw = 1671.7KB / s,iops = 417,runt = 627475msec cpu:usr = 0.63%,sys = 3.11%,ctx = 985926,majf = 0,minf = 22
2,558 IOPS-8 x 10K RPM 900GB SAS(2.5“)磁盘
测试:(g = 0):rw = randrw,bs = 4K-4K / 4K-4K-4K / 4K-4K,ioengine = libaio,iodepth = 64读取:io = 3071.7MB,bw = 10236KB / s,iops = 2558, runt = 307293msec写入:io = 1024.4MB,bw = 3413.5KB / s,iops = 853,runt = 307293msec cpu:usr = 2.73%,sys = 8.72%,ctx = 904875,majf = 0,minf = 25
23,456 IOPS-Rackspace Performance 2 SSD服务器
测试:(g = 0):rw = randrw,bs = 4K-4K / 4K-4K-4K / 4K-4K,ioengine = libaio,iodepth = 64读取:io = 3071.7MB,bw = 93708KB / s,iops = 23426, runt = 33566msec写入:io = 1024.4MB,bw = 31249KB / s,iops = 7812,runt = 33566msec cpu:usr = 5.73%,sys = 35.83%,ctx = 181568,majf = 0,minf = 23
35484 IOPS-2个Mirrored EDGE Boost 480GB 2.5英寸MLC(http://www.edgememory.com)
测试:(g = 0):rw = randrw,bs = 4K-4K / 4K-4K / 4K / 4K-4K,ioengine = libaio,iodepth = 64读取:io = 3068.4MB,bw = 141934KB / s,iops = 35483, runt = 22137msec写入:io = 1027.7MB,bw = 47537KB / s,iops = 11884,runt = 22137msec cpu:usr = 11.68%,sys = 69.89%,ctx = 24379,majf = 0,minf = 20
因此,很明显,当今的高质量SSD表现出色。两个镜像SSD可以轻松胜过16磁盘SAN存储机箱,这是一个令人信服的声明。
如果您对详细信息感兴趣,其余的文章可以在我的博客中找到:
http://www.juhavehnia.com/2015/05/using-ssds-to-improve-mysql-performance.html