|
4 | 4 | <title>Sourabh Bajaj</title>
|
5 | 5 | <link href="http://sourabhbajaj.com/" rel="self"/>
|
6 | 6 | <link href="http://sourabhbajaj.com"/>
|
7 |
| - <updated>2014-11-30T11:35:40-08:00</updated> |
| 7 | + <updated>2014-12-20T02:02:53-08:00</updated> |
8 | 8 | <id>http://sourabhbajaj.com</id>
|
9 | 9 | <author>
|
10 | 10 | <name>Sourabh Bajaj</name>
|
11 | 11 |
|
12 | 12 | </author>
|
13 | 13 |
|
14 | 14 |
|
| 15 | + <entry> |
| 16 | + <title>Redshift SSD Benchmarks</title> |
| 17 | + <link href="http://sourabhbajaj.com/redshift,%20data%20science,%20data%20warehousing/2014/12/20/redshift-ssd-benchmarks"/> |
| 18 | + <updated>2014-12-20T00:00:00-08:00</updated> |
| 19 | + <id>http://sourabhbajaj.com/redshift,%20data%20science,%20data%20warehousing/2014/12/20/redshift-ssd-benchmarks</id> |
| 20 | + <content type="html"> |
| 21 | +<p>Our warehouse runs completely on Redshift, and query performance is extremely important to us. Earlier this year, the AWS team announced the release of SSD instances for Amazon Redshift. Is the extra CPU truly worth it? We do a lot of processing with Redshift, so this question is big for us. To answer this, we decided to benchmark SSD performance and compare it to our original HDD performance.</p> |
| 22 | + |
| 23 | +<p>Redshift is easy to use because its PostgreSQL JDBC drivers allow us to use a range of familiar SQL clients. Its speedy performance is achieved through columnar storage and data compression.</p> |
| 24 | + |
| 25 | +<h2 id="experiment-setup">Experiment Setup</h2> |
| 26 | +<p>The Redshift instance specs are based off on-demand pricing, but the reserved instances can be 75% more affordable. The results from the benchmark are the mean run times after running each query 3 times.</p> |
| 27 | + |
| 28 | +<table class="table table-bordered table-striped table-hover"> |
| 29 | + <colgroup> |
| 30 | + <col span="1" style="width: 20%;" /> |
| 31 | + <col span="1" style="width: 20%;" /> |
| 32 | + <col span="1" style="width: 20%;" /> |
| 33 | + <col span="1" style="width: 20%;" /> |
| 34 | + <col span="1" style="width: 20%;" /> |
| 35 | + </colgroup> |
| 36 | + <thead> |
| 37 | + <tr> |
| 38 | + <td> </td> |
| 39 | + <td><b>HDD Setup 1</b></td> |
| 40 | + <td><b>HDD Setup 2</b></td> |
| 41 | + <td><b>SSD Setup 1</b></td> |
| 42 | + <td><b>SSD Setup 2</b></td> |
| 43 | + </tr> |
| 44 | + </thead> |
| 45 | + <tbody> |
| 46 | + <tr> |
| 47 | + <td><b>Nodes</b></td> |
| 48 | + <td>4 dw1.xlarge</td> |
| 49 | + <td>8 dw1.xlarge</td> |
| 50 | + <td>32 dw2.large</td> |
| 51 | + <td>4 dw2.8xlarge</td> |
| 52 | + </tr> |
| 53 | + <tr> |
| 54 | + <td><b>Storage</b></td> |
| 55 | + <td>8 TB</td> |
| 56 | + <td>16 TB</td> |
| 57 | + <td>5.12 TB</td> |
| 58 | + <td>10.24 TB</td> |
| 59 | + </tr> |
| 60 | + <tr> |
| 61 | + <td><b>Memory</b></td> |
| 62 | + <td>60 GB</td> |
| 63 | + <td>120 GB</td> |
| 64 | + <td>480 GB</td> |
| 65 | + <td>976 GB</td> |
| 66 | + </tr> |
| 67 | + <tr> |
| 68 | + <td><b>vCPU</b></td> |
| 69 | + <td>8</td> |
| 70 | + <td>16</td> |
| 71 | + <td>64</td> |
| 72 | + <td>128</td> |
| 73 | + </tr> |
| 74 | + <tr> |
| 75 | + <td><b>Price</b></td> |
| 76 | + <td>$3.4 / hr</td> |
| 77 | + <td>$6.8 / hr</td> |
| 78 | + <td>$8 / hr</td> |
| 79 | + <td>$19.2 / hr</td> |
| 80 | + </tr> |
| 81 | + </tbody> |
| 82 | +</table> |
| 83 | + |
| 84 | +<h3 id="query-1">Query 1.</h3> |
| 85 | +<p>First, we ran a simple join query between a table with 1 billion rows and a table with 50 million rows. The total amount of data processed was around 46GB. The results fell in favour of SSD’s.</p> |
| 86 | + |
| 87 | +<p><img src="https://dnsta5v53r71w.cloudfront.net/images/redshift-ssd-benchmark/1a.png" alt="Screenshot" style="width: 80%; margin-left:10%; margin-right:10%; margin-top:20px; margin-bottom:20px;" /></p> |
| 88 | + |
| 89 | +<h3 id="query-2">Query 2.</h3> |
| 90 | +<p>This complex query features REGEX matching and aggregate functions across 1 million rows from 4 joins. The total amount of data processed was around 100GB. The results fell even more in favour of SSD’s from 5x - 15x the performance improvement.</p> |
| 91 | + |
| 92 | +<p><img src="https://dnsta5v53r71w.cloudfront.net/images/redshift-ssd-benchmark/2.png" alt="Screenshot" style="width: 80%; margin-left:10%; margin-right:10%; margin-top:20px; margin-bottom:20px;" /></p> |
| 93 | + |
| 94 | +<h3 id="query-3">Query 3.</h3> |
| 95 | +<p>A query that runs window functions on a table of 1 billion rows showed surprising results. The total amount of data in this table is about 400GB. Although the SSD’s performed better, the smaller SSD’s out-performed the bigger SSD’s despite having double the memory and CPU power.</p> |
| 96 | + |
| 97 | +<p><img src="https://dnsta5v53r71w.cloudfront.net/images/redshift-ssd-benchmark/3.png" alt="Screenshot" style="width: 80%; margin-left:10%; margin-right:10%; margin-top:20px; margin-bottom:20px;" /></p> |
| 98 | + |
| 99 | +<h3 id="query-4">Query 4.</h3> |
| 100 | +<p>This last query has 4 join statements with a subquery that also includes 2 joins. The amount of data processed is around 107GB. Since this query is very compute-heavy, it is not surprising that SSD’s perform 10x better. What is shocking is that the smaller SSD’s are once again more performant than the bigger SSD’s.</p> |
| 101 | + |
| 102 | +<p><img src="https://dnsta5v53r71w.cloudfront.net/images/redshift-ssd-benchmark/4a.png" alt="Screenshot" style="width: 80%; margin-left:10%; margin-right:10%; margin-top:20px; margin-bottom:20px;" /></p> |
| 103 | + |
| 104 | +<h2 id="conclusion">Conclusion</h2> |
| 105 | +<p>We also ran some other queries and the performance improvement from HDD to SSD was consistent at about 5 - 10 times. From these experiments, the DW2 machines are clearly promising in terms of computation time. For the same price, SSD’s provide 3.4 times more CPU power and memory. However, the disk storage is about 25% of that of the HDD’s.</p> |
| 106 | + |
| 107 | +<p>A limitation to the dw2.large SSD instances is that a Redshift cluster can support at most 32 of them. That means dw2.large’s can provide at most 5.12 TB of disk storage. The only other option is to upgrade to dw2.8xlarge’s but this experiment shows little performance benefits from dw2.large’s to dw2.8xlarge’s despite doubling the memory and CPU.</p> |
| 108 | + |
| 109 | +<p><i><small>PS: This was originally written by Jason Shao on the <a href="https://tech.coursera.org/blog/2014/12/19/redshift-benchmark/">Coursera blog</a>.</small></i></p> |
| 110 | +</content> |
| 111 | + </entry> |
| 112 | + |
15 | 113 | <entry>
|
16 | 114 | <title>Pycon 2014 - Montreal</title>
|
17 | 115 | <link href="http://sourabhbajaj.com/python/2014/04/20/pycon-2014---montreal"/>
|
|
0 commit comments