View
4.751
Download
3
Category
Preview:
Citation preview
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
AWS マイスターシリーズ
Amazon Elastic Compute Cloud HPC編
2013.07.31
アマゾン データ サービス ジャパン株式会社
ソリューションアーキテクト 松尾 康博
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
2
アジェンダ
HPCとは?
HPCインスタンスの概要
HPCインスタンスの使い方
HPCインスタンスの活用
まとめ
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
3
アジェンダ
HPCとは?
HPCインスタンスの概要
HPCインスタンスの使い方
HPCインスタンスの活用
まとめ
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
4
HPCとは
HPCは狭義には、並列スーパーコンピュータ及びコンピュータ・クラスタ(主に汎用のCPU
を商用の相互結合網で結合し、単一のシステムとして構成された計算機システム)の利用を指す。その場合、HPCをハイ・パフォーマンス・クラスタリング (high-performance
clustering) の略とすることもある。また、クラスタリングにより高性能計算を実現する計算機をHPCC (high-performance computing cluster) と呼ぶ。
------snip----
科学研究に使われる計算に対して用いられることが多く、関連する用語に高性能技術計算(high performance technical computing、HPTC)がある。後者は一般にはクラスターベースの計算の工学的利用(例えば計算流体力学(computational fluid dynamics)や、仮
想的なプロトタイプの構築・試験など)を指す。最近では、クラスタベースの高性能計算機はビジネスにも利用されるようになってきた。例えばデータウェアハウス、LOBアプリケーション(line-of-business application)、トランザクション処理などである。
出典「Wikipedia 高性能計算」http://ja.wikipedia.org/wiki/高性能計算
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
5
AWSでのHPCとは
強力な計算処理能力が必要な分野に適したインスタンス
• 複雑な科学技術計算
• ビッグデータ
• 大規模データベース、データウェアハウス
ネットワーク
• 複数台で構成される計算クラスターを意識
• 広帯域、低遅延なネットワークを提供
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
6
アジェンダ
HPCとは?
HPCインスタンスの概要
HPCインスタンスの使い方
HPCインスタンスの活用
まとめ
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
7
HPCインスタンスタイプ 一覧
計算向け
• Cluster Compute 8XL (cc2.8xlarge)
• High Memory Cluster Compute (cr1.8xlarge)
• Cluster Compute 4XL (cc1.4xlarge)(東京リージョン未対応)
• Cluster GPU 4XL (cg1.4xlarge) (東京リージョン未対応)
高速I/O向け
• High IO 4XL (hi1.4xlarge)
大容量ストレージ
• High Storage 8XL (hs1.8xlarge)
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
8
256
128
64
32
16
8
4
2
1
1 2 4 8 16 32 64 128 256
High I/O 4XL 60.5 GB 35 EC2 Compute Units 16 virtual cores 2*1024 GB SSD-based local instance storage
EC2 Compute Units
Mem
ory
(G
B)
Small 1.7 GB, 1 EC2 Compute Unit 1 virtual core
Micro 613 MB Up to 2 ECUs (for short bursts)
Large 7.5 GB 4 EC2 Compute Units 2 virtual cores
Hi-Mem XL 17.1 GB 6.5 EC2 Compute Units 2 virtual cores
Hi-Mem 2XL 34.2 GB 13 EC2 Compute Units 4 virtual cores
Hi-Mem 4XL 68.4 GB 26 EC2 Compute Units 8 virtual cores
High-CPU Med 1.7 GB 5 EC2 Compute Units 2 virtual cores
High-CPU XL 7 GB 20 EC2 Compute Units 8 virtual cores
Medium 3.7 GB, 2 EC2 Compute Units 1 virtual core
M3 XL 15 GB 13 EC2 Compute Units 4 virtual cores EBS storage only
M3 2XL 30 GB 26 EC2 Compute Units 8 virtual cores EBS storage only
Extra Large 15 GB 8 EC2 Compute Units 4 virtual cores
10 GB Inter-
Instance Network
Cluster GPU 4XL 22 GB 33.5 EC2 Compute Units, 2 x NVIDIA Tesla “Fermi” M2050 GPUs
Cluster Compute 4XL 23 GB 33.5 EC2 Compute Units
Cluster Compute 8XL 60.5 GB 88 EC2 Compute Units
High Storage 8XL 117 GB 35 EC2 Compute Units, 24 * 2 TB ephemeral drives 10 GB Ethernet
Hi-Mem Cluster Compute 8XL 244 GB 88 EC2 Compute Units 16 virtual cores 240 GB SSD
インスタンスの種類
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
9
高性能スペック
CC2 インスタンス (cc2.8xlarge) 2世代目の、クラスタコンピュートインスタンスタイプ
HVM(完全仮想化)で実行
Intel® Xeon® E5-2670 processors x 2 (各種拡張命令も利用可能)
10 Gigabit Ethernet
1
Cluster Compute
80 ECU
物理16core
60GB RAM
840GB x 4
LocalDisk
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
10
大容量メモリスペック
CR1 インスタンス ( cr1.8xlarge) 3世代目の、大容量メモリクラスタコンピュートインスタンスタイプ
HVM(完全仮想化)で実行
Intel® Xeon® E5-2670 processors x 2 (各種拡張命令 + Intel Turbo, NUMA)
10 Gigabit Ethernet
2
Cluster Compute
80 ECU
物理16core
244GiB RAM
120GB x 2
Local SSD
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
11
高速 IO
HI1 インスタンス (hi1.4xlarge) 高速ファイルI/Oを実現するインスタンスタイプ
HVM(完全仮想化), PV(準仮想化) の両方で実行可能
10 Gigabit Ethernet
高速なSSDを内蔵
3
Cluster Compute
35 ECU
仮想16core
60.5 GB RAM
1TB x 2
Local SSD
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
12
大容量ストレージ
HS1 インスタンス (hs1.8xlarge) 大容量ストレージ向けコンピュートインスタンスタイプ
HVM(完全仮想化), PV(準仮想化) の両方で実行可能
10 Gigabit Ethernet
大容量のHDDを内蔵
4
Cluster Compute
35 ECU
仮想16core
117GiB RAM
2TB x 24
Local HDD
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
13
クラスタネットワーク
HPCインスタンス用API: Placement Groupを追加
論理クラスターを構築するネットワーク単位
1プレイスメントグループで220ノードを収容可能
複数のプレイスメントグループで構成した“Cluster of Clusters” で、より大きくスケール可能
従来のEC2と比べ、約10倍の帯域と1/10のレイテンシ
帯域 最大10Gbps
HPCインスタンス間は、JumboFrameを使用
ノンブロッキング
Full bisection の帯域
Placement Group内のインスタンス間の通信帯域は 10Gbps full bisectionのネットワーク
Full bisection bandwidth
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
14
High Performance Linpackの結果
2011年11月
• CC2.8xlarge (XeonE5, 10GbE)
• 1064ノード (17024コア)
• 240.09TFLOPS
• Top500 42位(当時)
• http://top500.org/system/177457
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
15
アジェンダ
HPCとは?
HPCインスタンスの概要
HPCインスタンスの使い方
HPCインスタンスの活用
まとめ
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
16
HPCインスタンスの起動方法
通常のインスタンスと異なる点
• 事前にPlacement Groupを作成
• 起動時に HVM AMIを選択
• 起動時に Placement Groupを指定
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
17
Placement Groupの作成と利用
APIの場合
ROMPT> ec2-create-placement-group XYZ-cluster -s cluster
PROMPT> ec2-run-instances ami-5f4d3a2b \
--instance-type cc2.8xlarge \
-n 10 --placement-group XYZ-cluster
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
18
Placement Groupの作成と利用
Management Console の場合
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
19
HVM AMIとは
HVM (ハードウェア仮想マシン) AMI
• 仮想化技術で分類すると、すべてのAMIはparavirtual か HVM に分類
• 通常のLinux AMIは paravirtual (Windowsは全て HVM)
• CC2, CR1は HVM AMIのみ利用可能
HVM AMI対応OS
• Amazon Linux
• Red Hat Enterprise Linux
• Windows
• その他コミュニティOS
• FreeBSD, CentOS, Ubuntu, Debian, etc.
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
20
HVM AMIが使えるインスタンスタイプ
HVM対応インスタンスタイプ ( 2013.7.31時点)
• 東京リージョンでは cc1, cg1が未対応
• Windows AMIでは全てのインスタンスタイプが選択可能
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
21
HVM AMIの探し方
Request Instances Wizardにて
• 「HVM image」と書いてあるAMIを選択する
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
22
HVM AMIの探し方
Quick Launch Wizard の検索機能を使う
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
23
HVM AMIの探し方
OS名称の下に表示される仮想化タイプがHVMになっている
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
24
カスタムHVM AMIの作成
既存のPublic HVM AMIから
• HVM AMIから インスタンスを起動
• 起動したインスタンスをカスタマイズ
• Create Image にて、カスタマイズしたインスタンスからイメージ作成
(※ paravirtual と手順は全く同じ)
制限事項
• Paravirtual AMIから HVM AMIに変換できない
• Paravirtual インスタンスから create imageで HVM AMIを作成できない
• ゼロからオリジナルのHVMを作成できない
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
25
HVM AMIの確認方法
インスタンスのDescriptionタブで確認
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
26
HVM AMIの注意点
Paravirtual AMIとの互換性
• Paravirtual AMIとHVM AMI間でAMI種別を変換することはできない。
• Paravirtual AMIで起動したインスタンス(例 t1.micro を 「change instance type」 で HVM インスタンス(例 cc2.8xlarge )に変更することはできない
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
27
アジェンダ
HPCとは?
HPCインスタンスの概要
HPCインスタンスの使い方
HPCインスタンスの活用
まとめ
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
28
HPC環境の構成例
EC2
計算ノード Amazon S3
データ
長期保管
(Online)
Amazon Elastic Block
Storage (EBS)
計算入力、計算結果
Lustre
ファイルシステム
計算中のデータ保持
Amazon EC2
NFSサーバー
Amazon EC2
管理サーバー
AWS Direct Connect
専用線接続
計算ノードの管理
ジョブの実行、管理
Amazon
Glacier
データ
長期保管
(Offline)
Scp/ftp/ etc S3 API
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
29
HPCツールと、パートナー製品
従来のクラスタ管理ソフトウェアの多くが利用可能 SGE Adaptive Computing – Moab, Torque Altair – PBS Platform – LSF Oracle – Grid Engine Univa-UD – UniCloud, GridMP Clustercorp – Rocks+Rolls Cycle Computing – Condor MIT - Starcluster
並列ファイルシステム Gluster Lustre GFS OrangeFS CEPH XtreemFS
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
30
HPCインスタンスのソフトウェア対応
様々なソフトウェアが利用可能
AWSでは、Intel MPI and Intel MKL® ライブラリを使用
OpenMPI, MPICH2なども利用可能
OpenFOAMなどのオープンソースも利用可能
Hadoop/ EMRも利用可能(東京リージョンは未対応)
その他様々なクラスタ管理ツール、ソフトウェアが利用可能
SAPなどのビジネス・アプリケーションも利用可能
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
31
EMRでも選択可能
EMR起動時に HPCインスタンスを選択可能
※東京リージョンは未対応
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
32
分散ファイルシステムの利用方法
インスタンスストレージを利用 ユーザが自分で分散ファイルシステムを構築可能
S3からデータを並列にコピー可能
クラスター起動中は、ファイルシステムを利用可能
Hi1では高速I/Oが実現可能、HS1では大容量を実現可能
EBSを利用 クラスタのライフサイクルに非依存な永続的なファイルシステムを構築可能
必要に応じて、クラスタを起動して、利用可能
S3にバックアップ(snapshot)可能
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
33
HPC用データ転送方法
標準的な方法 Scp/sftp/rsync/ftp
EBS/インスタンスストレージにコピー可能
クラスター起動中も、ファイルシステムを利用可能
高速転送ソリューションを利用 TsunamiUDP
Aspera
Skeed
Riverbed
参考:AWS Import/Export 物理的にDiskを送受信しAWS側で S3やEBSにImport/Exportを行う
参考:AWS Direct Connect 1Gbps/10GbpsでAWSへ専用線接続
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
34
クラスタの自動構成
AWSの様々な機能やツールでHPCクラスタを構築可能
• AWS API, AWS SDK
• CloudFormation
• OpsWorks
• Chef, Puppet, Capistorano, fabric
• StarCluster
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
35
StarClusterの紹介
MITで開発された 計算クラスターを簡単に構築・運用するツールキット
以下の様な構成が10分程度で構築可能
http://star.mit.edu/cluster/docs/latest/overview.html
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
36
StarClusterの実行例
$ starcluster start -s 16 samplecluster
StarCluster - (http://web.mit.edu/starcluster) (v. 0.93.3)
Software Tools for Academics and Researchers (STAR)
Please submit bug reports to starcluster@mit.edu
>>> Using default cluster template: smallcluster
>>> Validating cluster template settings...
>>> Cluster template settings are valid
>>> Starting cluster...
>>> Launching a 16-node cluster…
>>> Waiting for cluster to come up... (updating every 30s)
20/20 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| 100%
>>> Configuring SGE...
>>> Configuring NFS exports path(s):
/opt/sge6
>>> Mounting all NFS export path(s) on 16 worker node(s)
16/16 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| 100%
>>> Setting up NFS took 0.198 mins
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
37
StarCluster実行後
10分程度で、 16ノード(256core)のクラスタを構築
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
38
クラスター起動直後のマスターノード
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
39
アジェンダ
HPCとは?
HPCインスタンスの概要
HPCインスタンスの使い方
HPCインスタンスの活用
まとめ
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
40
まとめ
HPCインスタンスの特徴
• 高性能CPU, メモリ, ネットワーク, ディスクを利用可能
• HVM AMIを使用する
• 10GbEをフル活用するにはPlacement Groupを使う
HPC on AWS
• HPC領域でも、AWSの特徴はそのまま活用可能
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
41
AWS無料利用枠
アカウント取得から1年間有効
EC2関連では毎月以下が無料で利用可能
• EC2
• Linux マイクロインスタンス 750時間
• Microsoft Windows Server マイクロインスタンス 750時間
• EBS
• 30 GBのストレージ
• 200万 I/O、
• 1GBのスナップショット ストレージ
• データ転送
• 帯域幅「送信(アウト)」15 GB
http://aws.amazon.com/jp/free/
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
42
24時間・365日での日本語サポートの提供 日本語でのサポートをご提供しております http://aws.amazon.com/jp/premiumsupport/
ベーシック デベロッパー ビジネス エンタープライズ
受付時間 24時間 / 365日(年中無休)
初回応答時間 セルフサービス 12時間
(営業時間内) 1時間 15分
サポート連絡先 N/A 1人 5人 無制限
チャット 不可 不可 可能 可能
TEL 不可 不可 可能 可能
専任スタッフ なし なし なし あり
料金(月額) 無料(AWSの利用料に
含まれる) $49/月
AWS利用総額の 10%~
※最低料金:$100/月
AWS利用総額の 10%~
※最低$15,000/月
© 2012 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
43
追加のリソース
AWSのハイパフォーマンス・コンピューティング(HPC)
• http://aws.amazon.com/jp/hpc-applications/
Power of 60
• http://powerof60.com/
ビデオ
• 8ノードクラスタ構築
• http://www.youtube.com/watch?v=5zBxl6HUFA4
• 10分でHPCクラスタ構築
• http://www.youtube.com/watch?v=YfCgK1bmCjw
Recommended