1. ukinau

    No comment

    ukinau
Changes in body
Source | HTML | Preview
@@ -1,242 +1,242 @@
参考にした資料
- [openstack-murano-introduction by slideshare](http://www.slideshare.net/opendecoy/openstack-murano-introduction)
- [Murano公式レポジトリ](https://github.com/stackforge/murano/tree/stable/juno/contrib/devstack)
-###1. devstackをclone
+##1. devstackをclone
```
$ cd ~/
$ git clone https://github.com/openstack-dev/devstack.git
$ git checkout -b stable/juno origin/stable/juno
```
-###2. locarcのサンプルの取得/設定
+##2. locarcのサンプルの取得/設定
```
$ cd ~/devstack
$ git clone https://raw.githubusercontent.com/stackforge/Murano-deployment/release-0.4/getting-started/localrc
```
localrcのHOST_IP,default_password,FLOATING_RANGEに自分の環境にあった値を記入
-###3. Muranoのインストール用スクリプトの取得/配置/設定
+##3. Muranoのインストール用スクリプトの取得/配置/設定
```
$ cd ~/
$ git clone https://github.com/stackforge/murano.git
$ cp murano/contrib/devstack/lib/* devstack/lib
$ cp murano/contrib/devstack/extras.d/* devstack/extras.d
$ echo "ENABLED_SERVICES+=,murano,murano-api,murano-engine" >> ~/devstack/localrc
```
-###4. stack.shの実行
+##4. stack.shの実行
```
$ ~/devstack/stack.sh
2015-04-05 03:21:56.920 | + service=h-eng
2015-04-05 03:21:56.920 | + echo 'Error: Service h-eng is not running'
2015-04-05 03:21:56.920 | Error: Service h-eng is not running
2015-04-05 03:21:56.920 | + '[' -n /opt/stack/status/stack/h-eng.failure ']'
2015-04-05 03:21:56.921 | + die 1409 'More details about the above errors can be found with screen, with ./rejoin-stack.sh'
2015-04-05 03:21:56.921 | + local exitcode=0
2015-04-05 03:21:56.921 | [Call Trace]
2015-04-05 03:21:56.921 | ./stack.sh:1403:service_check
2015-04-05 03:21:56.921 | /home/ukinau/devstack/functions-common:1409:die
2015-04-05 03:21:56.926 | [ERROR] /home/ukinau/devstack/functions-common:1409 More details about the above errors can be found with screen, with ./rejoin-stack.sh
2015-04-05 03:21:57.930 | Error on exit
```
heat-engineの起動チェックで、コケてインストールが失敗しているように見えるが、heat-engine以外はキチンと起動しているので、下記手順でheat-engineを起動しプロセスレベルでは起動完了とする
-###5. heat-engineが依存しているライブラリのVersion違いに対応する
+##5. heat-engineが依存しているライブラリのVersion違いに対応する
参考バグ:https://bugs.launchpad.net/devstack/+bug/1404163
devstackでインストールされるバージョンだとダメだとheat-engineに怒られる(こんな感じ)
```
2015-04-04 23:20:47.629 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (sqlalchemy-migrate 0.9.6 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('sqlalchemy-migrate==0.9.1'))
```
のでバージョンをダウングレードします。
下記がバージョンを変更する必要があるパッケージ類です
```
$ sudo pip uninstall sqlalchemy-migrate
$ sudo pip uninstall python-heatclient
$ sudo pip uninstall oslo.utils
$ sudo pip uninstall oslo.messaging
$ sudo pip uninstall oslo.db
$ sudo pip uninstall oslo.i18n
$ sudo pip uninstall eventlet
$ sudo pip uninstall oslo.config
$ sudo pip uninstall keystonemiddleware
$ sudo pip install sqlalchemy-migrate==0.9.1
$ sudo pip install python-heatclient==0.2.9
$ sudo pip install oslo.utils==1.2.1
$ sudo pip install oslo.messaging==1.4.0
$ sudo pip install oslo.i18n==1.3.1
$ sudo pip install oslo.db==1.0.3
$ sudo pip install oslo.config==1.6.0
$ sudo pip install keystonemiddleware==1.3.0
$ sudo pip install eventlet==0.15.2
```
上記を実行したあとに、heat-engine実行
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
clients_keystone.endpoint_type = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.897 DEBUG heat.openstack.common.service [-] clients_keystone.insecure = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.899 DEBUG heat.openstack.common.service [-] clients_keystone.key_file = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.899 DEBUG heat.openstack.common.service [-] revision.heat_revision = unknown from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.899 DEBUG heat.openstack.common.service [-] ******************************************************************************** from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2075
2015-04-04 23:42:49.902 INFO oslo.messaging._drivers.impl_rabbit [-] Connected to AMQP server on 192.168.1.226:5672
```
分かりづらいですが、動きました。
これで、プロセスレベルではきちんと動いているように見えます。
Dashboardから操作しましょう。しかし。。。
-###6. Dashboardからpackageを操作しようとすると、エラーがでる
+##6. Dashboardからpackageを操作しようとすると、エラーがでる
参考バグhttps://bugs.launchpad.net/oslo-incubator/+bug/1328247
Murano-dashboardのlog.pyが古いので、最新版をコピーするとなおるらしい。
```
$ cp /opt/stack/horizon/openstack_dashboard/openstack/common/log.py /opt/stack/murano-dashboard/muranodashboard/openstack/common/log.py
$ sudo service apache2 restart
```
ここまでできて、OpenStack with Murano by devstackの起動完了です。
一通り試しましたが、他にエラーはでてません。
-###NextStep
+##NextStep
ここから先は、Muranoの利用方法についてなので、ドキュメントを読みながらよしなに、どうぞ
パッケージの登録をして、Enviromentを作ってDeployなどなど・・・
ひまがあれば、使い方のユースケースも次回投稿しますが、今日はここまで
---
-####参考資料(heat-engine起動の試行錯誤)
+###参考資料(heat-engine起動の試行錯誤)
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:20:47.629 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (sqlalchemy-migrate 0.9.6 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('sqlalchemy-migrate==0.9.1'))
$ sudo pip uninstall sqlalchemy-migrate
$ sudo pip install sqlalchemy-migrate==0.9.1
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $!>/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:24:13.454 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (python-heatclient 0.4.0 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('python-heatclient<0.3.0,>=0.2.9'))
$ sudo pip uninstall python-heatclient
$ sudo pip install python-heatclient==0.2.9
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:25:19.094 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (oslo.utils 1.4.0 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('oslo.utils<=1.2.1,>=1.0.0'))
$ sudo pip uninstall oslo.utils
$ sudo pip install oslo.utils==1.2.1
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:26:23.542 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (oslo.messaging 1.8.1 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('oslo.messaging<1.5.0,>=1.4.0'))
$ sudo pip uninstall oslo.messaging
$ sudo pip install oslo.messaging==1.4.0
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:36:47.025 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (oslo.i18n 1.5.0 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('oslo.i18n<=1.3.1,>=1.0.0'))
$ sudo pip uninstall oslo.i18n
$ sudo pip install oslo.i18n==1.3.1
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:38:02.831 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (oslo.db 1.7.1 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('oslo.db<1.1,>=1.0.0'))
$ sudo pip uninstall oslo.db
$ sudo pip install oslo.db==1.0.3
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:38:54.489 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (oslo.config 1.9.3 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('oslo.config<=1.6.0,>=1.4.0'))
$ sudo pip uninstall oslo.config
$ sudo pip install oslo.config==1.6.0
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:40:25.153 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (keystonemiddleware 1.5.0 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('keystonemiddleware<1.4.0,>=1.0.0'))
$ sudo pip uninstall keystonemiddleware
$ sudo pip install keystonemiddleware==1.3.0
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:41:47.161 CRITICAL heat.engine [-] Could not load AWSTemplateFormatVersion.2010-09-09: (eventlet 0.17.2 (/usr/local/lib/python2.7/dist-packages), Requirement.parse('eventlet<=0.15.2,>=0.15.1'))
$ sudo pip uninstall eventlet
$ sudo pip install eventlet==0.15.2
```
```
$ /opt/stack/heat/bin/heat-engine --config-file=/etc/heat/heat.conf & echo $! >/opt/stack/status/stack/h-eng.pid; fg || echo "h-eng failed to start" | tee "/opt/stack/status/stack/h-eng.failure"
2015-04-04 23:42:49.893 DEBUG heat.openstack.common.service [-] heat_api_cfn.workers = 0 from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.895 DEBUG heat.openstack.common.service [-] auth_password.allowed_auth_uris = [] from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.895 DEBUG heat.openstack.common.service [-] auth_password.multi_cloud = False from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.896 DEBUG heat.openstack.common.service [-] clients_keystone.ca_file = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.896 DEBUG heat.openstack.common.service [-] clients_keystone.cert_file = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.896 DEBUG heat.openstack.common.service [-] clients_keystone.endpoint_type = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.897 DEBUG heat.openstack.common.service [-] clients_keystone.insecure = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.899 DEBUG heat.openstack.common.service [-] clients_keystone.key_file = None from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.899 DEBUG heat.openstack.common.service [-] revision.heat_revision = unknown from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2073
2015-04-04 23:42:49.899 DEBUG heat.openstack.common.service [-] ******************************************************************************** from (pid=825) log_opt_values /usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py:2075
2015-04-04 23:42:49.902 INFO oslo.messaging._drivers.impl_rabbit [-] Connected to AMQP server on 192.168.1.226:5672
```