EC2のカリフォルニアリージョン

カリフォルニアに新しいEC2リージョンが出来たそうです。
http://aws.amazon.com/ec2/

The Northern California Region
You can now choose to locate your AWS resources in our Northern California Region, which like other AWS Regions, contains multiple redundant Availability Zones. Utilizing this Region can reduce your data access latencies if you have customers or existing data centers in the Northern California area. This new Region is available for Amazon EC2, Amazon Simple Storage Service (Amazon S3), Amazon SimpleDB, Amazon Simple Queue Service (Amazon SQS), and Amazon Elastic MapReduce. For Northern California Region pricing, please see the detail page for each service on aws.amazon.com.


今までのUSロケーションはバージニア州にあり、今回のカリフォルニア州はちょうど反対側になります。


日本から接続する場合、地理的に近い方がレスポンスが良いので、カリフォルニアにサーバを立てると、単純にアメリカ大陸一個分通信が早くなる計算になります。


ということで、早速インスタンスを起動して、レスポンス速度を計ってみました。


インスタンス起動

AWS Management Consoleを立ち上げると、新しいリージョンが選べるようになっています。


こんにちはカリフォルニア

Apacheインストール

ひとまずDebian+最小インスタンスで起動します。起動はほかのリージョンと変わりません。
起動後、Apacheをインストールします。


計測用に、Apacheに30Kbyteぐらいの画像を載せておきます。

計測

測定にはabを使用し、10クライアント100リクエストで測定しました。
まずはバージニア州。

Document Path: /tetsu_out.png
Document Length: 29994 bytes

Concurrency Level: 10
Time taken for tests: 10.684435 seconds
Complete requests: 100
Failed requests: 0
Write errors: 0
Total transferred: 3031500 bytes
HTML transferred: 2999400 bytes
Requests per second: 9.36 [#/sec] (mean)
Time per request: 1068.443 [ms] (mean)
Time per request: 106.844 [ms] (mean, across all concurrent requests)
Transfer rate: 277.04 [Kbytes/sec] received

Connection Times (ms)
min mean[+/-sd] median max
Connect: 182 197 8.2 198 217
Processing: 742 816 84.4 807 1447
Waiting: 184 199 8.9 200 222
Total: 928 1013 87.5 1004 1648

Percentage of the requests served within a certain time (ms)
50% 1004
66% 1030
75% 1038
80% 1044
90% 1061
95% 1081
98% 1367
99% 1648
100% 1648 (longest request)


次にカリフォルニア州

Document Path: /tetsu_out.png
Document Length: 29994 bytes

Concurrency Level: 10
Time taken for tests: 7.40270 seconds
Complete requests: 100
Failed requests: 0
Write errors: 0
Total transferred: 3208370 bytes
HTML transferred: 3181513 bytes
Requests per second: 14.20 [#/sec] (mean)
Time per request: 704.027 [ms] (mean)
Time per request: 70.403 [ms] (mean, across all concurrent requests)
Transfer rate: 445.01 [Kbytes/sec] received

Connection Times (ms)
min mean[+/-sd] median max
Connect: 117 126 6.3 125 146
Processing: 483 529 73.9 519 1202
Waiting: 118 129 30.2 127 423
Total: 602 656 75.6 647 1330

Percentage of the requests served within a certain time (ms)
50% 647
66% 655
75% 667
80% 670
90% 687
95% 705
98% 826
99% 1330
100% 1330 (longest request)


おおよそですが、3割ほどレスポンスが良くなっています。何度か測定しましたが、大体こんな感じでした。
なかなかいい感じですね!シュアちゃんも大喜びです。

問題点?

速度3割増しならすぐにでも移行したいところですが、料金がEUリージョンと同じ設定で、インスタンス使用料や通信料が若干割高です。
バージニアの最小インスタンスが1時間$0.085に対して、カリフォルニアが$0.095と、大体1割増ぐらいです。


ただ、最近利用料が安くなり、カリフォルニアを選んでも以前より安くなっているので、十分選択肢に入るかと思います。