Fedora23でやろうとしたんだけど、今後、仕事でサーバ構築にFedoraを使うかというと微妙すぎた(FedoraはあくまでRedHatへのフィードバックディストリビューションの位置付け)ので、CentOS7をVMWareFusionでVM(メモリ4GB、HDD150GB)を用意して、これにRDOを使ってOpenStackをインストールすることにした。
構築の仕方は
RDO QuickStartを見ながら。
RDOリポジトリの追加とアップデート
まずはパッケージのアップデートとRDOのリポジトリを追加しておく
$ yum -y install https://www.rdoproject.org/repos/rdo-release.rpm
読み込んだプラグイン:fastestmirror
rdo-release.rpm | 5.1 kB 00:00:00
/var/tmp/yum-root-jzdiyf/rdo-release.rpm を調べています: rdo-release-liberty-2.noarch
/var/tmp/yum-root-jzdiyf/rdo-release.rpm をインストール済みとして設定しています
依存性の解決をしています
--> トランザクションの確認を実行しています。
---> パッケージ rdo-release.noarch 0:liberty-2 を インストール
--> 依存性解決を終了しました。
依存性を解決しました
========================================================================================================================
Package アーキテクチャー バージョン リポジトリー 容量
========================================================================================================================
インストール中:
rdo-release noarch liberty-2 /rdo-release 1.4 k
トランザクションの要約
========================================================================================================================
インストール 1 パッケージ
合計容量: 1.4 k
インストール容量: 1.4 k
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
インストール中 : rdo-release-liberty-2.noarch 1/1
検証中 : rdo-release-liberty-2.noarch 1/1
インストール:
rdo-release.noarch 0:liberty-2
完了しました!
packstackコマンドをインストールする
$ yum -y install openstack-packstack
シングルノードでのOpenStack構築
$ packstack --allinone
Welcome to the Packstack setup utility
The installation log file is available at: /var/tmp/packstack/20160223-040412-NQg7pb/openstack-setup.log
Packstack changed given value to required value /root/.ssh/id_rsa.pub
Installing:
Clean Up [ DONE ]
Discovering ip protocol version [ DONE ]
Setting up ssh keys [ DONE ]
Preparing servers [ DONE ]
Pre installing Puppet and discovering hosts' details [ DONE ]
Adding pre install manifest entries [ DONE ]
Setting up CACERT [ DONE ]
Adding AMQP manifest entries [ DONE ]
Adding MariaDB manifest entries [ DONE ]
Fixing Keystone LDAP config parameters to be undef if empty[ DONE ]
Adding Keystone manifest entries [ DONE ]
Adding Glance Keystone manifest entries [ DONE ]
Adding Glance manifest entries [ DONE ]
Adding Cinder Keystone manifest entries [ DONE ]
Checking if the Cinder server has a cinder-volumes vg[ DONE ]
Adding Cinder manifest entries [ DONE ]
Adding Nova API manifest entries [ DONE ]
Adding Nova Keystone manifest entries [ DONE ]
Adding Nova Cert manifest entries [ DONE ]
Adding Nova Conductor manifest entries [ DONE ]
Creating ssh keys for Nova migration [ DONE ]
Gathering ssh host keys for Nova migration [ DONE ]
Adding Nova Compute manifest entries [ DONE ]
Adding Nova Scheduler manifest entries [ DONE ]
Adding Nova VNC Proxy manifest entries [ DONE ]
Adding OpenStack Network-related Nova manifest entries[ DONE ]
Adding Nova Common manifest entries [ DONE ]
Adding Neutron VPNaaS Agent manifest entries [ DONE ]
Adding Neutron FWaaS Agent manifest entries [ DONE ]
Adding Neutron LBaaS Agent manifest entries [ DONE ]
Adding Neutron API manifest entries [ DONE ]
Adding Neutron Keystone manifest entries [ DONE ]
Adding Neutron L3 manifest entries [ DONE ]
Adding Neutron L2 Agent manifest entries [ DONE ]
Adding Neutron DHCP Agent manifest entries [ DONE ]
Adding Neutron Metering Agent manifest entries [ DONE ]
Adding Neutron Metadata Agent manifest entries [ DONE ]
Adding Neutron SR-IOV Switch Agent manifest entries [ DONE ]
Checking if NetworkManager is enabled and running [ DONE ]
Adding OpenStack Client manifest entries [ DONE ]
Adding Horizon manifest entries [ DONE ]
Adding Swift Keystone manifest entries [ DONE ]
Adding Swift builder manifest entries [ DONE ]
Adding Swift proxy manifest entries [ DONE ]
Adding Swift storage manifest entries [ DONE ]
Adding Swift common manifest entries [ DONE ]
Adding Provisioning Demo manifest entries [ DONE ]
Adding Provisioning Demo bridge manifest entries [ DONE ]
Adding Provisioning Glance manifest entries [ DONE ]
Adding MongoDB manifest entries [ DONE ]
Adding Redis manifest entries [ DONE ]
Adding Ceilometer manifest entries [ DONE ]
Adding Ceilometer Keystone manifest entries [ DONE ]
Adding Nagios server manifest entries [ DONE ]
Adding Nagios host manifest entries [ DONE ]
Adding post install manifest entries [ DONE ]
Copying Puppet modules and manifests [ DONE ]
Applying 172.16.33.181_prescript.pp
172.16.33.181_prescript.pp: [ DONE ]
Applying 172.16.33.181_amqp.pp
Applying 172.16.33.181_mariadb.pp
172.16.33.181_amqp.pp: [ DONE ]
172.16.33.181_mariadb.pp: [ DONE ]
Applying 172.16.33.181_keystone.pp
Applying 172.16.33.181_glance.pp
Applying 172.16.33.181_cinder.pp
172.16.33.181_keystone.pp: [ DONE ]
172.16.33.181_glance.pp: [ DONE ]
172.16.33.181_cinder.pp: [ DONE ]
Applying 172.16.33.181_api_nova.pp
172.16.33.181_api_nova.pp: [ DONE ]
Applying 172.16.33.181_nova.pp
172.16.33.181_nova.pp: [ DONE ]
Applying 172.16.33.181_neutron.pp
172.16.33.181_neutron.pp: [ DONE ]
Applying 172.16.33.181_osclient.pp
Applying 172.16.33.181_horizon.pp
172.16.33.181_osclient.pp: [ DONE ]
172.16.33.181_horizon.pp: [ DONE ]
Applying 172.16.33.181_ring_swift.pp
172.16.33.181_ring_swift.pp: [ DONE ]
Applying 172.16.33.181_swift.pp
Applying 172.16.33.181_provision_demo.pp
172.16.33.181_swift.pp: [ DONE ]
172.16.33.181_provision_demo.pp: [ DONE ]
Applying 172.16.33.181_provision_demo_bridge.pp
172.16.33.181_provision_demo_bridge.pp: [ DONE ]
Applying 172.16.33.181_provision_glance
172.16.33.181_provision_glance: [ DONE ]
Applying 172.16.33.181_mongodb.pp
Applying 172.16.33.181_redis.pp
172.16.33.181_mongodb.pp: [ DONE ]
172.16.33.181_redis.pp: [ DONE ]
Applying 172.16.33.181_ceilometer.pp
172.16.33.181_ceilometer.pp: [ DONE ]
Applying 172.16.33.181_nagios.pp
Applying 172.16.33.181_nagios_nrpe.pp
172.16.33.181_nagios.pp: [ DONE ]
172.16.33.181_nagios_nrpe.pp: [ DONE ]
Applying 172.16.33.181_postscript.pp
172.16.33.181_postscript.pp: [ DONE ]
Applying Puppet manifests [ DONE ]
Finalizing [ DONE ]
**** Installation completed successfully ******
Additional information:
* A new answerfile was created in: /root/packstack-answers-20160223-040413.txt
* Time synchronization installation was skipped. Please note that unsynchronized time on server instances might be problem for some OpenStack components.
* Warning: NetworkManager is active on 172.16.33.181. OpenStack networking currently does not work on systems that have the Network Manager service enabled.
* File /root/keystonerc_admin has been created on OpenStack client host 172.16.33.181. To use the command line tools you need to source the file.
* To access the OpenStack Dashboard browse to http://172.16.33.181/dashboard .
Please, find your login credentials stored in the keystonerc_admin in your home directory.
* To use Nagios, browse to http://172.16.33.181/nagios username: nagiosadmin, password: ead818c11ae742b9
* The installation log file is available at: /var/tmp/packstack/20160223-040412-NQg7pb/openstack-setup.log
* The generated manifests are available at: /var/tmp/packstack/20160223-040412-NQg7pb/manifests
最後の方にこんなWarningが出てたけど、無事にdashboardにアクセスできた!
* Warning: NetworkManager is active on 172.16.33.181. OpenStack networking currently does not work on systems that have the Network Manager service enabled.
この画面でログインする時のID、PASSWORDは
~/keystonerc_adminに残っているのでそのアカウントでログインする。
$ cat ~/keystonerc_admin
unset OS_SERVICE_TOKEN
export OS_USERNAME=admin
export OS_PASSWORD=ef6d2d3aa7d2474c
export OS_AUTH_URL=http://172.16.33.181:5000/v2.0
export PS1='[\u@\h \W(keystone_admin)]\$ '
export OS_TENANT_NAME=admin
export OS_REGION_NAME=RegionOne
ようやくログインできた。