Xen の設定
NC をインストールするサーバでは、次のコマンドを実行し、Xen の設定をします。
1 | sed -i -e 's/#(xend-http-server no)/(xend-http-server yes)/' /etc/xen/xend-config.sxp |
2 | sed -i -e 's/#(xend-address localhost)/(xend-address localhost)/' /etc/xen/xend-config.sxp |
3 | # 設定を反映させるため、Xenのサービスを再起動 |
4 | /etc/init.d/xend restart |
なお、Eucalyptus を構成する各サーバとクライアントPC は時刻が正しく同期できていることが必要であるため、別途ntp を使って時刻同期の設定を行ってください。OS のインストールと設定が終わったら、次にEucalyptus のインストールを行います。
Eucalyptus のインストール
フロントエンドのインストール
はじめに、フロントエンドをインストールします。Eucalyptus のパッケージをインストールする前に、Eucalyptus の動作に必要な依存パッケージをインストールします。
1 | yum install -y java-1.6.0-openjdk ant ant-nodeps dhcp bridge-utils httpd \ |
2 | scsi-target-utils perl-Convert-ASN1 |
次に、Eucalyptus のパッケージを公式サイト注1 からダウンロードします。「REL-5/CentOS-5RPMs 64-bit」用のパッケージを選択し、「 eucalyptus-2.0.2-centos-x86_64.tar.gz 」をダウンロードします( 図4 )。

|
図4:パッケージのダウンロード(クリックで拡大) |
ダウンロードしたファイルをフロントエンドに配置し、次のように展開して、展開したディレクトリに移動します。
1 | tar xzvf eucalyptus-2.0.2-centos-x86_64.tar.gz |
2 | cd eucalyptus-2.0.2-centos-x86_64/eucalyptus-2.0.2-rpm-deps-x86_64/ |
Eucalyptus が依存するサードパーティ製のRPM パッケージをインストールします。
01 | rpm -Uvh aoetools-21-1.el4.x86_64.rpm \ |
02 | euca-axis2c-1.6.0-1.x86_64.rpm \ |
03 | euca-rampartc-1.3.0-1.x86_64.rpm \ |
04 | vblade-14-1mdv2008.1.x86_64.rpm \ |
05 | vtun-3.0.2-1.el5.rf.x86_64.rpm \ |
06 | lzo2-2.02-3.el5.rf.x86_64.rpm \ |
07 | perl-Crypt-OpenSSL-Random-0.04-1.el5.rf.x86_64.rpm \ |
08 | perl-Crypt-OpenSSL-RSA-0.25-1.el5.rf.x86_64.rpm \ |
09 | perl-Crypt-X509-0.32-1.el5.rf.noarch.rpm \ |
10 | python25-2.5.1-bashton1.x86_64.rpm \ |
11 | python25-devel-2.5.1-bashton1.x86_64.rpm \ |
12 | python25-libs-2.5.1-bashton1.x86_64.rpm |
注1 http://open.eucalyptus.com/downloads
最後に、Eucalyptus のRPM パッケージをインストールします。
1 | rpm -Uvh eucalyptus-2.0.2-1.x86_64.rpm \ |
2 | eucalyptus-common-java-2.0.2-1.x86_64.rpm \ |
3 | eucalyptus-cloud-2.0.2-1.x86_64.rpm \ |
4 | eucalyptus-walrus-2.0.2-1.x86_64.rpm \ |
5 | eucalyptus-sc-2.0.2-1.x86_64.rpm \ |
6 | eucalyptus-cc-2.0.2-1.x86_64.rpm \ |
7 | eucalyptus-gl-2.0.2-1.x86_64.rpm |
◆◇◆◇ NOTE Python 2.5 で実行するための修正 ◆◇◆◇
Eucalyptus 2.0 系で実装された管理用コマンドですが、執筆時点のバージョン(eucalyptus-2.0.0
~ eucalyptus-2.0.2)のCentOS 用RPM パッケージに含まれているものはshebang が「 /user/bin/env python 」と記述されており、CentOS 標準のPython 2.4 で実行してしまいます。そのため、次のコマンドを実行してPython 2.5 で実行するように修正する必要があります。
1 | for cmd in `rpm -ql eucalyptus-2.0.2-1 | grep '/usr/sbin/euca-'`; do |
2 | sed -i -e 's|^\(#!/usr/bin/env python\)$|\12.5|' ${cmd} |