- 论坛徽章:
- 0
|
此为连载教程,会在几天内发布完成,内容顺序如下:
1. 在CentOS 6.3上通过源码安装Openstack Folsom之Keystone安装
2. 在CentOS 6.3上通过源码安装Openstack Folsom之Glance安装
3. 在CentOS 6.3上通过源码安装Openstack Folsom之Nova安装
4. 在CentOS 6.3上通过源码安装Openstack Folsom之OpenVswitch安装
5. 在CentOS 6.3上通过源码安装Openstack Folsom之Quantum安装
6. 在CentOS 6.3上通过源码安装Openstack Folsom之Cinder安装
7. 在CentOS 6.3上通过源码安装Openstack Folsom之Nova使用Quantum
8. 在CentOS 6.3上通过源码安装Openstack Folsom之Novnc安装
9. 在CentOS 6.3上通过源码安装Openstack Folsom之Horizon安装
10. 在CentOS 6.3上通过源码安装Openstack Folsom之通过Glance上传镜像
11. 在CentOS 6.3上通过源码安装Openstack Folsom之通过Horizon启动实例
系统环境- CentOS 6.3 x86_64
- Openstack Folsom
- 服务器IP:172.16.24.138
- 注:因为用到了Quantum,系统需要至少两块网卡
- 这里使用的flat+dhcp模式,类似于nova-network的flatmanager模式,所以网段最好跟物理机网段一致,后面会单独发帖讲解gre和local还有vlan模式
复制代码 1. Horizon安装- wget https://launchpad.net/horizon/folsom/2012.2/+download/horizon-2012.2.tar.gz
- tar xf horizon-2012.2.tar.gz
- cd horizon-2012.2/tools
- pip-python install -r pip-requires
- cd ..
- python setup.py install
复制代码 1.1 安装NodeJS- wget http://nodejs.org/dist/v0.8.12/node-v0.8.12.tar.gz
- tar xf node-v0.8.12.tar.gz
- cd node-v0.8.12
- ./configure --prefix=/usr/local/nodejs-0.8.12
- make && make install
- ln -sv /usr/local/nodejs-0.8.12/bin/node /usr/bin/
复制代码 1.2 创建Horizon配置文件- cp /opt/horizon-2012.2/openstack_dashboard/local/local_settings.py.example /opt/horizon-2012.2/openstack_dashboard/local/local_settings.py
复制代码 1.3 向local_settings.py文件添加如下内容- DATABASES = {
- 'default': {
- 'ENGINE': 'django.db.backends.mysql',
- 'NAME': 'horizon',
- 'USER': 'root',
- 'PASSWORD': '123456',
- 'HOST': 'localhost',
- 'PORT': '3306',
- },
- }
复制代码 1.4 在/etc/httpd/conf.d/目录下新建openstack-dashboard.conf文件,内容如下- <VirtualHost *:80>
- WSGIScriptAlias /horizon /opt/horizon-2012.2/openstack_dashboard/wsgi/django.wsgi
- WSGIDaemonProcess horizon user=apache group=apache processes=3 threads=10 home=/opt/horizon-2012.2
- WSGIApplicationGroup horizon
-
- SetEnv APACHE_RUN_USER apache
- SetEnv APACHE_RUN_GROUP apache
- WSGIProcessGroup horizon
-
- DocumentRoot /opt/horizon-2012.2/.blackhole/
- Alias /media /opt/horizon-2012.2/openstack_dashboard/static
-
- <Directory />
- Options FollowSymLinks
- AllowOverride None
- </Directory>
-
- <Directory /opt/horizon-2012.2/>
- Options Indexes FollowSymLinks MultiViews
- AllowOverride None
- Order allow,deny
- Allow from all
- </Directory>
-
- ErrorLog /var/log/httpd/horizon_error.log
- LogLevel warn
- CustomLog /var/log/httpd/horizon_access.log combined
- </VirtualHost>
- WSGISocketPrefix /var/run/horizon
复制代码 1.5 同步数据库及设置目录权限- mkdir /opt/horizon-2012.2/.blackhole
- chown -R apache:apache /opt/horizon-2012.2
- python /opt/horizon-2012.2/manage.py syncdb --noinput
- /etc/init.d/httpd start
复制代码 现在就可以通过http://ip/horizon访问dashboard了 |
|